components/tmux/patches/winsz.patch
author Tomas Kuthan <tomas.kuthan@oracle.com>
Wed, 20 Apr 2016 13:13:57 -0700
changeset 5820 cef0da89f9ee
parent 3717 b16a04ab5d50
permissions -rw-r--r--
PSARC/2016/216 OpenSSH 7.2p2 upgrade. Host keys and moduli updates 23030875 network/ssh SMF method: generate correct host key types

ioctl(TIOCSWINSZ) will sporadically fail with an ENXIO.  Ignoring this
harmless condition doesn't affect tmux behavior.
In-house patch.  Has been filed upstream as ticket #158
    https://sourceforge.net/p/tmux/tickets/158/
Patch was accepted by maintainer, will be included in the next stable version.
--- ORIGINAL/server-client.c	2014-02-19 13:44:07.000000000 -0800
+++ tmux-1.9/server-client.c	2014-11-20 11:17:33.896630008 -0800
@@ -541,7 +541,8 @@
 	ws.ws_row = wp->sy;
 
 	if (ioctl(wp->fd, TIOCSWINSZ, &ws) == -1)
-		fatal("ioctl failed");
+		if (errno != EINVAL && errno != ENXIO)
+			fatal("ioctl failed");
 
 	wp->flags &= ~PANE_RESIZE;
 }