desktop-shell: fix DEREF_AFTER_NULL 65/55665/1
authorSangjin Lee <lsj119@samsung.com>
Mon, 28 Dec 2015 11:09:41 +0000 (20:09 +0900)
committerSangjin Lee <lsj119@samsung.com>
Mon, 28 Dec 2015 11:09:41 +0000 (20:09 +0900)
Change-Id: Ie96a803f7e56d0ff23af3fefd2da0dd900be4d07

src/lib/desktop-shell/xdg-shell.c

index f6bc945d4adb308f3515fb86b43ab67afa83dd41..bffdab0a3ab10d0b4d0c2962a6acd6080e9589be 100644 (file)
@@ -259,7 +259,10 @@ xdg_shell_get_xdg_surface(struct wl_client      *client,
     shsurf = shell_surface_create(shell_client, surface, client, &xdg_surface_interface,
                                   &xdg_surface_implementation, 1, id);
     if (!shsurf)
+    {
         wl_client_post_no_memory(client);
+        return ;
+    }
 
     shell_surface_set_toplevel(shsurf);
 }