From 2a69ea8bd6d087a9634562defe2b53e28aa6c40f Mon Sep 17 00:00:00 2001 From: Timo Kokkonen Date: Fri, 23 Jul 2010 14:04:21 +0300 Subject: [PATCH] main.c: Clear the options structure before using Obviously it is not guaranteed that the contents of the structure are zeroed if the content is allocated from the stack.. Signed-off-by: Timo Kokkonen --- main.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/main.c b/main.c index 75db469..c629938 100644 --- a/main.c +++ b/main.c @@ -68,6 +68,8 @@ int main(int argc, char *argv[]) struct process *process_list = NULL; struct parse_opts opts; + memset(&opts, 0, sizeof(opts)); + read_args(argc, argv, &opts); if (argc < 3) { -- 2.45.0