diff --git a/proc/readproc.c b/proc/readproc.c index 0b88242a..61633612 100644 --- a/proc/readproc.c +++ b/proc/readproc.c @@ -37,6 +37,7 @@ #include #include #include +#include #ifdef WITH_SYSTEMD #include #endif @@ -1369,7 +1370,7 @@ PROCTAB* openproc(unsigned flags, ...) { va_list ap; struct stat sbuf; static int did_stat; - PROCTAB* PT = malloc(sizeof(PROCTAB)); + PROCTAB* PT = calloc(1, sizeof(PROCTAB)); if (!PT) return NULL;