summaryrefslogtreecommitdiffstats
path: root/window.c
diff options
context:
space:
mode:
authornicm <nicm>2016-09-28 08:30:44 +0000
committernicm <nicm>2016-09-28 08:30:44 +0000
commitacacb718e5452bfdba4810007d5a10eace1a9fec (patch)
treeafd9330825aebdc0705562f8e781ef98b991c98b /window.c
parent69e980602b31732348aaceee045a1901dc982d78 (diff)
Rate limit TIOCSWINSZ on a timer to avoid programs getting hammered with
SIGWINCH when the size changes rapidly. To help a problem reported by Rui Pinheiro.
Diffstat (limited to 'window.c')
-rw-r--r--window.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/window.c b/window.c
index 33fdd8e7..84b6cc5a 100644
--- a/window.c
+++ b/window.c
@@ -803,6 +803,9 @@ window_pane_destroy(struct window_pane *wp)
close(wp->pipe_fd);
}
+ if (event_initialized(&wp->resize_timer))
+ event_del(&wp->resize_timer);
+
RB_REMOVE(window_pane_tree, &all_window_panes, wp);
free((void *)wp->cwd);