aboutsummaryrefslogtreecommitdiff
path: root/tmux.h
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@openbsd.org>2010-08-11 07:34:43 +0000
committerNicholas Marriott <nicm@openbsd.org>2010-08-11 07:34:43 +0000
commit8363e31953a346b3cd4141bf30a8d79d37ca2674 (patch)
tree1052ae596f467e6f915c555530ce6b64df31e621 /tmux.h
parent933dc48de356e387c0c027e654e1ae5f2f24c711 (diff)
downloadrtmux-8363e31953a346b3cd4141bf30a8d79d37ca2674.tar.gz
rtmux-8363e31953a346b3cd4141bf30a8d79d37ca2674.tar.bz2
rtmux-8363e31953a346b3cd4141bf30a8d79d37ca2674.zip
Change the way backoff works. Instead of stopping reading from the pty
when the client tty backs up too much, just stop updating the tty and only update the internal screen. Then when the tty recovers, force a redraw. This prevents a dodgy client from causing other clients to go into backoff while still allowing tmux to be responsive (locally) when seeing lots of output.
Diffstat (limited to 'tmux.h')
-rw-r--r--tmux.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/tmux.h b/tmux.h
index e1cd0b7e..af731ff7 100644
--- a/tmux.h
+++ b/tmux.h
@@ -59,8 +59,8 @@ extern char **environ;
/* Automatic name refresh interval, in milliseconds. */
#define NAME_INTERVAL 500
-/* Maximum data to buffer for output before suspending reading from panes. */
-#define BACKOFF_THRESHOLD 1024
+/* Maximum data to buffer for output before suspending writing to a tty. */
+#define BACKOFF_THRESHOLD 16384
/*
* Maximum sizes of strings in message data. Don't forget to bump
@@ -1017,6 +1017,7 @@ struct tty {
#define TTY_UTF8 0x8
#define TTY_STARTED 0x10
#define TTY_OPENED 0x20
+#define TTY_BACKOFF 0x40
int flags;
int term_flags;
@@ -1126,6 +1127,8 @@ struct client {
#define CLIENT_DEAD 0x200
#define CLIENT_BORDERS 0x400
#define CLIENT_READONLY 0x800
+#define CLIENT_BACKOFF 0x1000
+#define CLIENT_REDRAWWINDOW 0x2000
int flags;
struct event identify_timer;