From: Adam Dickmeiss Date: Tue, 4 Nov 2014 10:22:44 +0000 (+0100) Subject: Merge branch 'master' of ssh://git.indexdata.com/home/git/pub/yaz X-Git-Tag: v5.6.0~3 X-Git-Url: http://git.indexdata.com/?p=yaz-moved-to-github.git;a=commitdiff_plain;h=1b7419b08b3ac1d58bc8a147a5a563174276e151;hp=049669818c2933243d5a578e4111b75278b77407 Merge branch 'master' of ssh://git.indexdata.com/home/git/pub/yaz --- diff --git a/src/tcpip.c b/src/tcpip.c index 3ade82b..e2e2014 100644 --- a/src/tcpip.c +++ b/src/tcpip.c @@ -1328,7 +1328,13 @@ int tcpip_put(COMSTACK h, char *buf, int size) h->io_pending = CS_WANT_WRITE; return 1; } - return cont_connect(h); + if (h->flags & CS_FLAGS_BLOCKING) + { + h->cerrno = CSYSERR; + return -1; + } + else + return cont_connect(h); } state->written += res; TRC(fprintf(stderr, " Wrote %d, written=%d, nbytes=%d\n",