diff options
author | Damien Miller <djm@mindrot.org> | 2000-07-08 02:57:08 +0200 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2000-07-08 02:57:08 +0200 |
commit | f2fdbe5540c3954bd62a6ec6d701132a65110d27 (patch) | |
tree | ea12f6af9f07a863df085715f25b263f39026513 /atomicio.c | |
parent | *** empty log message *** (diff) | |
download | openssh-f2fdbe5540c3954bd62a6ec6d701132a65110d27.tar.xz openssh-f2fdbe5540c3954bd62a6ec6d701132a65110d27.zip |
- (djm) Handle EWOULDBLOCK returns from read() and write() in atomicio.c
Fix from Marquess, Steve Mr JMLFDC <Steve.Marquess@DET.AMEDD.ARMY.MIL>
Diffstat (limited to 'atomicio.c')
-rw-r--r-- | atomicio.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/atomicio.c b/atomicio.c index 7d9f9340c..45da22d3b 100644 --- a/atomicio.c +++ b/atomicio.c @@ -46,7 +46,11 @@ atomicio(f, fd, _s, n) res = (f) (fd, s + pos, n - pos); switch (res) { case -1: +#ifdef EWOULDBLOCK + if (errno == EINTR || errno == EAGAIN || errno == EWOULDBLOCK) +#else if (errno == EINTR || errno == EAGAIN) +#endif continue; case 0: return (res); |