wayland: Don't overwrite error message from SDL_EGL_CreateSurface

SDL_EGL_CreateSurface sets a more specific error message, so overwriting
it would lose information.

Signed-off-by: Simon McVittie <smcv@collabora.com>
This commit is contained in:
Simon McVittie 2022-03-24 18:30:32 +00:00 committed by Ethan Lee
parent d5bbbd3f73
commit b4d28085bf
1 changed files with 1 additions and 1 deletions

View File

@ -1325,7 +1325,7 @@ int Wayland_CreateWindow(_THIS, SDL_Window *window)
data->egl_surface = SDL_EGL_CreateSurface(_this, (NativeWindowType) data->egl_window);
if (data->egl_surface == EGL_NO_SURFACE) {
return SDL_SetError("failed to create an EGL window surface");
return -1; /* SDL_EGL_CreateSurface should have set error */
}
#endif
}