summaryrefslogtreecommitdiffstats
path: root/usr.bin/tmux/cmd-set-option.c
diff options
context:
space:
mode:
authornicm <nicm@openbsd.org>2015-04-24 23:17:11 +0000
committernicm <nicm@openbsd.org>2015-04-24 23:17:11 +0000
commit82873134f2d306f798ef1248fddc2aa3717c7b74 (patch)
tree8f4b3079882ecc246acc53cbcb6a898c4b63ecca /usr.bin/tmux/cmd-set-option.c
parentSet working directory for run-shell and if-shell. (diff)
downloadwireguard-openbsd-82873134f2d306f798ef1248fddc2aa3717c7b74.tar.xz
wireguard-openbsd-82873134f2d306f798ef1248fddc2aa3717c7b74.zip
Convert clients list into a TAILQ.
Diffstat (limited to 'usr.bin/tmux/cmd-set-option.c')
-rw-r--r--usr.bin/tmux/cmd-set-option.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/usr.bin/tmux/cmd-set-option.c b/usr.bin/tmux/cmd-set-option.c
index 52f8ebcdc4b..33f2b675512 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.73 2015/04/24 21:38:18 nicm Exp $ */
+/* $OpenBSD: cmd-set-option.c,v 1.74 2015/04/24 23:17:11 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -91,7 +91,6 @@ cmd_set_option_exec(struct cmd *self, struct cmd_q *cmdq)
struct options *oo;
struct window *w;
const char *optstr, *valstr;
- u_int i;
/* Get the option name and value. */
optstr = args->argv[0];
@@ -186,9 +185,8 @@ cmd_set_option_exec(struct cmd *self, struct cmd_q *cmdq)
/* Update sizes and redraw. May not need it but meh. */
recalculate_sizes();
- for (i = 0; i < ARRAY_LENGTH(&clients); i++) {
- c = ARRAY_ITEM(&clients, i);
- if (c != NULL && c->session != NULL)
+ TAILQ_FOREACH(c, &clients, entry) {
+ if (c->session != NULL)
server_redraw_client(c);
}