summaryrefslogtreecommitdiff
path: root/xwayland
diff options
context:
space:
mode:
authorBryce W. Harrington <b.harrington@samsung.com>2014-04-21 23:51:03 +0000
committerKristian Høgsberg <krh@bitplanet.net>2014-04-25 13:20:10 -0700
commita212cbb0e684ec9b60ba050cf79b501ba9af6895 (patch)
tree1024223eb198b6ac2e23a0dcfbf50264ed17b3a8 /xwayland
parentbfd74f40f3804a42a9135b3aef01f626372153ab (diff)
xwayland: Check zalloc return for out of memory situation
Signed-off-by: Bryce Harrington <b.harrington@samsung.com>
Diffstat (limited to 'xwayland')
-rw-r--r--xwayland/launcher.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/xwayland/launcher.c b/xwayland/launcher.c
index ac692ded..70703a4b 100644
--- a/xwayland/launcher.c
+++ b/xwayland/launcher.c
@@ -348,6 +348,8 @@ module_init(struct weston_compositor *compositor,
char lockfile[256], display_name[8];
wxs = zalloc(sizeof *wxs);
+ if (wxs == NULL)
+ return -1;
wxs->process.cleanup = weston_xserver_cleanup;
wxs->wl_display = display;
wxs->compositor = compositor;