malloc + memset -> zalloc
And for clients using the xmalloc helper, use xzalloc.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
diff --git a/src/shell.c b/src/shell.c
index 30b55c3..ebe9b9f 100644
--- a/src/shell.c
+++ b/src/shell.c
@@ -4443,11 +4443,10 @@
unsigned int i;
struct wl_event_loop *loop;
- shell = malloc(sizeof *shell);
+ shell = zalloc(sizeof *shell);
if (shell == NULL)
return -1;
- memset(shell, 0, sizeof *shell);
shell->compositor = ec;
shell->destroy_listener.notify = shell_destroy;