diff options
author | 2014-01-15 11:44:18 +0000 | |
---|---|---|
committer | 2014-01-15 11:44:18 +0000 | |
commit | b5cbd9e8958034b05e88fa8a1dfa381215fc2590 (patch) | |
tree | e19e9e1d26d6533c8023c1368440fde86eeef79f /usr.bin/tmux/arguments.c | |
parent | Add WSDISPLAYIO_SETGFXMODE ioctl on LUNA's frame buffer. (diff) | |
download | wireguard-openbsd-b5cbd9e8958034b05e88fa8a1dfa381215fc2590.tar.xz wireguard-openbsd-b5cbd9e8958034b05e88fa8a1dfa381215fc2590.zip |
Couple of fixes from cppcheck via Tiago Cunha.
Diffstat (limited to 'usr.bin/tmux/arguments.c')
-rw-r--r-- | usr.bin/tmux/arguments.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/usr.bin/tmux/arguments.c b/usr.bin/tmux/arguments.c index 46c012f3450..5d3fa331ce2 100644 --- a/usr.bin/tmux/arguments.c +++ b/usr.bin/tmux/arguments.c @@ -1,4 +1,4 @@ -/* $OpenBSD: arguments.c,v 1.7 2014/01/09 13:51:57 nicm Exp $ */ +/* $OpenBSD: arguments.c,v 1.8 2014/01/15 11:44:18 nicm Exp $ */ /* * Copyright (c) 2010 Nicholas Marriott <nicm@users.sourceforge.net> @@ -78,7 +78,6 @@ struct args * args_parse(const char *template, int argc, char **argv) { struct args *args; - char *ptr; int opt; args = xcalloc(1, sizeof *args); @@ -89,7 +88,7 @@ args_parse(const char *template, int argc, char **argv) while ((opt = getopt(argc, argv, template)) != -1) { if (opt < 0) continue; - if (opt == '?' || (ptr = strchr(template, opt)) == NULL) { + if (opt == '?' || strchr(template, opt) == NULL) { args_free(args); return (NULL); } |