summaryrefslogtreecommitdiffstats
path: root/usr.bin/tmux/arguments.c
diff options
context:
space:
mode:
authornicm <nicm@openbsd.org>2014-01-15 11:44:18 +0000
committernicm <nicm@openbsd.org>2014-01-15 11:44:18 +0000
commitb5cbd9e8958034b05e88fa8a1dfa381215fc2590 (patch)
treee19e9e1d26d6533c8023c1368440fde86eeef79f /usr.bin/tmux/arguments.c
parentAdd WSDISPLAYIO_SETGFXMODE ioctl on LUNA's frame buffer. (diff)
downloadwireguard-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.c5
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);
}