summaryrefslogtreecommitdiff
path: root/usr.bin
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@cvs.openbsd.org>2011-01-04 01:58:13 +0000
committerNicholas Marriott <nicm@cvs.openbsd.org>2011-01-04 01:58:13 +0000
commit4ed01ace53ae40f281e939f327e60a3026e2535a (patch)
treea04204c92dc375f72e04a20a78583e5c72bd169c /usr.bin
parent8851e37c6ee514ca63fb431cf43f35c6603001d9 (diff)
argc will be 1 not 2 with no option value.
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/tmux/cmd-set-option.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/tmux/cmd-set-option.c b/usr.bin/tmux/cmd-set-option.c
index 13af83d4d61..3a8c7ef35ac 100644
--- a/usr.bin/tmux/cmd-set-option.c
+++ b/usr.bin/tmux/cmd-set-option.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cmd-set-option.c,v 1.44 2011/01/04 00:42:47 nicm Exp $ */
+/* $OpenBSD: cmd-set-option.c,v 1.45 2011/01/04 01:58:12 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -115,7 +115,7 @@ cmd_set_option_exec(struct cmd *self, struct cmd_ctx *ctx)
ctx->error(ctx, "invalid option");
return (-1);
}
- if (args->argc < 1)
+ if (args->argc < 2)
valstr = NULL;
else
valstr = args->argv[1];