zalloc the libinput_source, don't malloc it

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
This commit is contained in:
Peter Hutterer 2015-02-03 09:36:17 +10:00
parent 154b3cf749
commit 536dd6a40f

View file

@ -510,7 +510,7 @@ libinput_add_fd(struct libinput *libinput,
struct libinput_source *source;
struct epoll_event ep;
source = malloc(sizeof *source);
source = zalloc(sizeof *source);
if (!source)
return NULL;