aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2003-03-11 19:07:41 +0000
committerDaniel Stenberg <daniel@haxx.se>2003-03-11 19:07:41 +0000
commitc2d8025a0ae50200592ef87a386b742c07352027 (patch)
tree7da703df11860d1afefd416f3ae879467dc2ee4f /lib
parent853e240e1d5ca8e1fb9c550b7823ce9d55aef3a9 (diff)
Christophe Demory fixed the check to work better for non-blocking on HP-UX
systems. Bug report #701749.
Diffstat (limited to 'lib')
-rw-r--r--lib/sendf.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/sendf.c b/lib/sendf.c
index 7901108c1..26d1831d8 100644
--- a/lib/sendf.c
+++ b/lib/sendf.c
@@ -270,7 +270,11 @@ CURLcode Curl_write(struct connectdata *conn, int sockfd,
#ifdef WIN32
if(WSAEWOULDBLOCK == GetLastError())
#else
- if(EWOULDBLOCK == errno)
+ /* As pointed out by Christophe Demory on March 11 2003, errno
+ may be EWOULDBLOCK or on some systems EAGAIN when it returned
+ due to its inability to send off data without blocking. We
+ therefor treat both error codes the same here */
+ if((EWOULDBLOCK == errno) || ((EAGAIN == errno))
#endif
{
/* this is just a case of EWOULDBLOCK */