diff options
author | Nicholas Marriott <nicm@cvs.openbsd.org> | 2020-08-19 07:15:43 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@cvs.openbsd.org> | 2020-08-19 07:15:43 +0000 |
commit | b1c76213ea9218d3823866f7dd850875db91b45d (patch) | |
tree | 3b19faf3672b179b7910d9bf383e81f19dce7ac4 /usr.bin/tmux/alerts.c | |
parent | 08af00ae7de19a601b5ff3fd5acd53ba37a6a9b4 (diff) |
Set alert flag for the current window if the session is unattached.
GitHub issues 1182 and 2299. From Eric Garver.
Diffstat (limited to 'usr.bin/tmux/alerts.c')
-rw-r--r-- | usr.bin/tmux/alerts.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.bin/tmux/alerts.c b/usr.bin/tmux/alerts.c index dc3240b1468..71fb3b88cea 100644 --- a/usr.bin/tmux/alerts.c +++ b/usr.bin/tmux/alerts.c @@ -1,4 +1,4 @@ -/* $OpenBSD: alerts.c,v 1.31 2020/07/27 08:03:10 nicm Exp $ */ +/* $OpenBSD: alerts.c,v 1.32 2020/08/19 07:15:42 nicm Exp $ */ /* * Copyright (c) 2015 Nicholas Marriott <nicholas.marriott@gmail.com> @@ -200,7 +200,7 @@ alerts_check_bell(struct window *w) * not check WINLINK_BELL). */ s = wl->session; - if (s->curw != wl) { + if (s->curw != wl || s->attached == 0) { wl->flags |= WINLINK_BELL; server_status_session(s); } @@ -236,7 +236,7 @@ alerts_check_activity(struct window *w) if (wl->flags & WINLINK_ACTIVITY) continue; s = wl->session; - if (s->curw != wl) { + if (s->curw != wl || s->attached == 0) { wl->flags |= WINLINK_ACTIVITY; server_status_session(s); } @@ -272,7 +272,7 @@ alerts_check_silence(struct window *w) if (wl->flags & WINLINK_SILENCE) continue; s = wl->session; - if (s->curw != wl) { + if (s->curw != wl || s->attached == 0) { wl->flags |= WINLINK_SILENCE; server_status_session(s); } |