Skip to content

Commit

Permalink
Wayland: changed a few "SetError(); return -1;" to "return SetError()".
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Apr 8, 2015
1 parent b620df3 commit 9a686aa
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
3 changes: 1 addition & 2 deletions src/video/wayland/SDL_waylandmouse.c
Expand Up @@ -356,8 +356,7 @@ Wayland_WarpMouseGlobal(int x, int y)
static int
Wayland_SetRelativeMouseMode(SDL_bool enabled)
{
SDL_Unsupported();
return -1;
return SDL_Unsupported();
}

void
Expand Down
3 changes: 1 addition & 2 deletions src/video/wayland/SDL_waylandvideo.c
Expand Up @@ -324,8 +324,7 @@ Wayland_GetDisplayModes(_THIS, SDL_VideoDisplay *sdl_display)
static int
Wayland_SetDisplayMode(_THIS, SDL_VideoDisplay *display, SDL_DisplayMode *mode)
{
SDL_SetError("SetDisplayMode not (yet?) supported on Wayland.");
return -1;
return SDL_Unsupported();
}

void
Expand Down
3 changes: 1 addition & 2 deletions src/video/wayland/SDL_waylandwindow.c
Expand Up @@ -186,8 +186,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) {
SDL_SetError("failed to create a window surface");
return -1;
return SDL_SetError("failed to create a window surface");;
}

if (data->shell_surface) {
Expand Down

0 comments on commit 9a686aa

Please sign in to comment.