From 1c667bce3fe0209b976ac8e3c3d32ec7a1530e9a Mon Sep 17 00:00:00 2001 From: Martin Willi Date: Thu, 20 Feb 2014 11:20:45 +0100 Subject: pki: Make cmds array static, ensuring that it is zero-initialized As pki --help relies on a zero-terminated array, make the actually non-public cmds array static to ensure initialization. --- src/pki/command.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/pki') diff --git a/src/pki/command.c b/src/pki/command.c index 7ccbd96f4..b6966ee0b 100644 --- a/src/pki/command.c +++ b/src/pki/command.c @@ -29,7 +29,7 @@ /** * Registered commands. */ -command_t cmds[MAX_COMMANDS]; +static command_t cmds[MAX_COMMANDS]; /** * active command. @@ -274,4 +274,3 @@ int command_dispatch(int c, char *v[]) } return command_usage(c > 1 ? "invalid operation" : NULL); } - -- cgit v1.2.3