diff options
author | rsc <devnull@localhost> | 2005-01-20 22:59:50 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2005-01-20 22:59:50 +0000 |
commit | f0264abf2684f96c011ad56b292378a67074c148 (patch) | |
tree | c258ecffc636b332a3a8113b33d4476333c18a96 /src/cmd/samterm/plan9.c | |
parent | 303cb7c6dbb49fd57cb97af77f93fab620eee8d7 (diff) | |
download | plan9port-f0264abf2684f96c011ad56b292378a67074c148.tar.gz plan9port-f0264abf2684f96c011ad56b292378a67074c148.tar.bz2 plan9port-f0264abf2684f96c011ad56b292378a67074c148.zip |
ignore host read eof while exiting
Diffstat (limited to 'src/cmd/samterm/plan9.c')
-rw-r--r-- | src/cmd/samterm/plan9.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/cmd/samterm/plan9.c b/src/cmd/samterm/plan9.c index 5f5c33d0..3d2df85d 100644 --- a/src/cmd/samterm/plan9.c +++ b/src/cmd/samterm/plan9.c @@ -279,6 +279,11 @@ hostproc(void *arg) n = read(hostfd[0], hostbuf[i].data, sizeof hostbuf[i].data); if(0) fprint(2, "hostproc %d\n", n); if(n <= 0){ + if(n == 0){ + if(exiting) + threadexits(nil); + werrstr("unexpected eof"); + } fprint(2, "samterm: host read error: %r\n"); threadexitsall("host"); } |