diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | channels.c | 3 | ||||
-rw-r--r-- | serverloop.c | 6 |
3 files changed, 11 insertions, 4 deletions
@@ -1,3 +1,7 @@ | |||
1 | 20060625 | ||
2 | - (dtucker) [channels.c serverloop.c] Apply the bug #1102 workaround to ptys | ||
3 | only, otherwise sshd can hang exiting non-interactive sessions. | ||
4 | |||
1 | 20060624 | 5 | 20060624 |
2 | - (dtucker) [configure.ac] Bug #1193: Define PASSWD_NEEDS_USERNAME on Solaris. | 6 | - (dtucker) [configure.ac] Bug #1193: Define PASSWD_NEEDS_USERNAME on Solaris. |
3 | Works around limitation in Solaris' passwd program for changing passwords | 7 | Works around limitation in Solaris' passwd program for changing passwords |
@@ -4704,4 +4708,4 @@ | |||
4704 | - (djm) Trim deprecated options from INSTALL. Mention UsePAM | 4708 | - (djm) Trim deprecated options from INSTALL. Mention UsePAM |
4705 | - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu | 4709 | - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu |
4706 | 4710 | ||
4707 | $Id: ChangeLog,v 1.4348 2006/06/24 06:58:45 dtucker Exp $ | 4711 | $Id: ChangeLog,v 1.4349 2006/06/24 22:25:25 dtucker Exp $ |
diff --git a/channels.c b/channels.c index 239e9dd83..9642a56ee 100644 --- a/channels.c +++ b/channels.c | |||
@@ -1422,7 +1422,8 @@ channel_handle_rfd(Channel *c, fd_set *readset, fd_set *writeset) | |||
1422 | #ifndef PTY_ZEROREAD | 1422 | #ifndef PTY_ZEROREAD |
1423 | if (len <= 0) { | 1423 | if (len <= 0) { |
1424 | #else | 1424 | #else |
1425 | if (len < 0 || (len == 0 && errno != 0)) { | 1425 | if ((!c->isatty && len <= 0) || |
1426 | (c->isatty && (len < 0 || (len == 0 && errno != 0)))) { | ||
1426 | #endif | 1427 | #endif |
1427 | debug2("channel %d: read<=0 rfd %d len %d", | 1428 | debug2("channel %d: read<=0 rfd %d len %d", |
1428 | c->self, c->rfd, len); | 1429 | c->self, c->rfd, len); |
diff --git a/serverloop.c b/serverloop.c index e370f63a3..18f1a10bd 100644 --- a/serverloop.c +++ b/serverloop.c | |||
@@ -394,7 +394,8 @@ process_input(fd_set *readset) | |||
394 | #ifndef PTY_ZEROREAD | 394 | #ifndef PTY_ZEROREAD |
395 | } else if (len <= 0) { | 395 | } else if (len <= 0) { |
396 | #else | 396 | #else |
397 | } else if (len < 0 || (len == 0 && errno != 0)) { | 397 | } else if ((!isatty(fdout) && len <= 0) || |
398 | (isatty(fdout) && (len < 0 || (len == 0 && errno != 0)))) { | ||
398 | #endif | 399 | #endif |
399 | fdout_eof = 1; | 400 | fdout_eof = 1; |
400 | } else { | 401 | } else { |
@@ -411,7 +412,8 @@ process_input(fd_set *readset) | |||
411 | #ifndef PTY_ZEROREAD | 412 | #ifndef PTY_ZEROREAD |
412 | } else if (len <= 0) { | 413 | } else if (len <= 0) { |
413 | #else | 414 | #else |
414 | } else if (len < 0 || (len == 0 && errno != 0)) { | 415 | } else if ((!isatty(fderr) && len <= 0) || |
416 | (isatty(fderr) && (len < 0 || (len == 0 && errno != 0)))) { | ||
415 | #endif | 417 | #endif |
416 | fderr_eof = 1; | 418 | fderr_eof = 1; |
417 | } else { | 419 | } else { |