diff --git a/src/SFML/Window/EglContext.cpp b/src/SFML/Window/EglContext.cpp index ec62e8025..44f87357b 100644 --- a/src/SFML/Window/EglContext.cpp +++ b/src/SFML/Window/EglContext.cpp @@ -427,7 +427,7 @@ XVisualInfo EglContext::selectBestVisual(::Display* XDisplay, unsigned int bitsP // Get X11 visuals compatible with this EGL config int visualCount = 0; - auto availableVisuals = X11Ptr XGetVisualInfo(XDisplay, VisualIDMask, &vTemplate, &visualCount)); + auto availableVisuals = X11Ptr(XGetVisualInfo(XDisplay, VisualIDMask, &vTemplate, &visualCount)); if (visualCount == 0) {