Wayland: Fixed crash if memory mapping failed while creating a custom cursor.
authorPhilipp Wiesemann <philipp.wiesemann@arcor.de>
Wed, 16 Mar 2016 22:09:39 +0100
changeset 10120 f49e8a97c214
parent 10119 ac9831ff70d1
child 10121 6b6ded44e6e0
Wayland: Fixed crash if memory mapping failed while creating a custom cursor.
src/video/wayland/SDL_waylandmouse.c
--- a/src/video/wayland/SDL_waylandmouse.c	Wed Mar 16 22:09:23 2016 +0100
+++ b/src/video/wayland/SDL_waylandmouse.c	Wed Mar 16 22:09:39 2016 +0100
@@ -130,6 +130,7 @@
         d->shm_data = NULL;
         fprintf (stderr, "mmap () failed\n");
         close (shm_fd);
+        return -1;
     }
 
     shm_pool = wl_shm_create_pool(data->shm, shm_fd, size);