malloc + memset -> zalloc

And for clients using the xmalloc helper, use xzalloc.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
Peter Hutterer
2013-08-08 11:57:05 +10:00
committed by Kristian Høgsberg
parent b1bc4a68b0
commit f3d62276d2
35 changed files with 68 additions and 138 deletions
+1 -3
View File
@@ -325,9 +325,7 @@ module_init(struct weston_compositor *compositor,
struct weston_xserver *wxs;
char lockfile[256], display_name[8];
wxs = malloc(sizeof *wxs);
memset(wxs, 0, sizeof *wxs);
wxs = zalloc(sizeof *wxs);
wxs->process.cleanup = weston_xserver_cleanup;
wxs->wl_display = display;
wxs->compositor = compositor;