diff options
author | David Sterba <dsterba@suse.com> | 2016-03-01 16:02:08 +0100 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2016-03-14 13:42:47 +0100 |
commit | babe94e4817aca45aef409b7a21bc47e51cda6ff (patch) | |
tree | a00641b956754d6bd002bb23c6b8e3d3a18b8740 /cmds-rescue.c | |
parent | c27640938de1506e0a02f7f928a00886d5da616a (diff) |
btrfs-progs: add getopt stubs where needed
Commands that do not take any options do not use getopt, which means the
standard option separator "--" does not work. Update all command
handlers that need it, argv needs to be referenced using the optind that
is correctly pointed after the separator.
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'cmds-rescue.c')
-rw-r--r-- | cmds-rescue.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/cmds-rescue.c b/cmds-rescue.c index 98954254..cacb1448 100644 --- a/cmds-rescue.c +++ b/cmds-rescue.c @@ -165,6 +165,8 @@ static int cmd_rescue_zero_log(int argc, char **argv) char *devname; int ret; + clean_args_no_options(argc, argv, cmd_rescue_zero_log_usage); + if (check_argc_exact(argc, 2)) usage(cmd_rescue_zero_log_usage); |