From: Bryce W. Harrington Date: Mon, 21 Apr 2014 23:51:03 +0000 (+0000) Subject: xwayland: Check zalloc return for out of memory situation X-Git-Tag: 1.4.92~42 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a212cbb0e684ec9b60ba050cf79b501ba9af6895;p=platform%2Fupstream%2Fweston.git xwayland: Check zalloc return for out of memory situation Signed-off-by: Bryce Harrington --- diff --git a/xwayland/launcher.c b/xwayland/launcher.c index ac692de..70703a4 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;