diff options
author | 2020-01-28 08:06:11 +0000 | |
---|---|---|
committer | 2020-01-28 08:06:11 +0000 | |
commit | b5f8268c723931d29cccf07f97f6669e78ee6f75 (patch) | |
tree | b2547789539054cfcb48b14e6994fb86bca34f30 /usr.bin/tmux/resize.c | |
parent | changes to support FIDO attestation (diff) | |
download | wireguard-openbsd-b5f8268c723931d29cccf07f97f6669e78ee6f75.tar.xz wireguard-openbsd-b5f8268c723931d29cccf07f97f6669e78ee6f75.zip |
Add a define for flags meaning a client is not attached, and fix
unattached counter, reported by Thomas Sattler.
Diffstat (limited to 'usr.bin/tmux/resize.c')
-rw-r--r-- | usr.bin/tmux/resize.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/usr.bin/tmux/resize.c b/usr.bin/tmux/resize.c index 2ac2993a437..2fc565c4d71 100644 --- a/usr.bin/tmux/resize.c +++ b/usr.bin/tmux/resize.c @@ -1,4 +1,4 @@ -/* $OpenBSD: resize.c,v 1.36 2019/11/29 16:04:07 nicm Exp $ */ +/* $OpenBSD: resize.c,v 1.37 2020/01/28 08:06:11 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicholas.marriott@gmail.com> @@ -363,14 +363,15 @@ recalculate_sizes(void) * client. */ TAILQ_FOREACH(c, &clients, entry) { + s = c->session; + if (s != NULL && !(c->flags & CLIENT_UNATTACHEDFLAGS)) + s->attached++; if (ignore_client_size(c)) continue; - s = c->session; if (c->tty.sy <= s->statuslines || (c->flags & CLIENT_CONTROL)) c->flags |= CLIENT_STATUSOFF; else c->flags &= ~CLIENT_STATUSOFF; - s->attached++; } /* Walk each window and adjust the size. */ |