chiark / gitweb /
systemctl: make sure getopt doesn't segfault
[elogind.git] / src / systemctl.c
index be32b0d..4afe53e 100644 (file)
@@ -1343,7 +1343,8 @@ static int parse_argv(int argc, char *argv[]) {
                 { "replace",   no_argument,       NULL, ARG_REPLACE },
                 { "session",   no_argument,       NULL, ARG_SESSION },
                 { "system",    no_argument,       NULL, ARG_SYSTEM  },
-                { "block",     no_argument,       NULL, ARG_BLOCK   }
+                { "block",     no_argument,       NULL, ARG_BLOCK   },
+                { NULL,        0,                 NULL, 0           }
         };
 
         int c;