aboutsummaryrefslogtreecommitdiff
path: root/cmd-set-option.c
diff options
context:
space:
mode:
authorTiago Cunha <tcunha@gmx.com>2011-01-07 14:51:54 +0000
committerTiago Cunha <tcunha@gmx.com>2011-01-07 14:51:54 +0000
commitb2b5d88f3f828c5ac972097967a58a192cad4fca (patch)
tree9ddff3d16a082ba05dd5a56ba83507e8cbace676 /cmd-set-option.c
parentecec113b63c4bb05cc1de0549753c0c3adb5bb1d (diff)
downloadrtmux-b2b5d88f3f828c5ac972097967a58a192cad4fca.tar.gz
rtmux-b2b5d88f3f828c5ac972097967a58a192cad4fca.tar.bz2
rtmux-b2b5d88f3f828c5ac972097967a58a192cad4fca.zip
Sync OpenBSD patchset 830:
argc will be 1 not 2 with no option value.
Diffstat (limited to 'cmd-set-option.c')
-rw-r--r--cmd-set-option.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/cmd-set-option.c b/cmd-set-option.c
index 2056d7b7..8e052c2d 100644
--- a/cmd-set-option.c
+++ b/cmd-set-option.c
@@ -1,4 +1,4 @@
-/* $Id: cmd-set-option.c,v 1.105 2011-01-07 14:45:34 tcunha Exp $ */
+/* $Id: cmd-set-option.c,v 1.106 2011-01-07 14:51:54 tcunha 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];