mirror of
https://github.com/tmux/tmux.git
synced 2026-02-15 02:29:19 +00:00
Don't call event_add again if the event is already pending, from Conor
Taylor in GitHub issue 4848.
This commit is contained in:
3
tty.c
3
tty.c
@@ -628,7 +628,8 @@ tty_add(struct tty *tty, const char *buf, size_t len)
|
|||||||
|
|
||||||
if (tty_log_fd != -1)
|
if (tty_log_fd != -1)
|
||||||
write(tty_log_fd, buf, len);
|
write(tty_log_fd, buf, len);
|
||||||
if (tty->flags & TTY_STARTED)
|
if ((tty->flags & TTY_STARTED) &&
|
||||||
|
!event_pending(&tty->event_out, EV_WRITE, NULL))
|
||||||
event_add(&tty->event_out, NULL);
|
event_add(&tty->event_out, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user