X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=comstack%2Ftcpip.c;h=a71069e3510105dc031b41d1f078ff50c1330b74;hb=3aefb04b1ebd1a699ab732b7504fdf25a2c35fa7;hp=3a99bd09828e5f2e66ea94fac8aa74863ef8d02e;hpb=044d170f0a963555486df54653cd2fdc5815928b;p=yaz-moved-to-github.git diff --git a/comstack/tcpip.c b/comstack/tcpip.c index 3a99bd0..a71069e 100644 --- a/comstack/tcpip.c +++ b/comstack/tcpip.c @@ -1,10 +1,18 @@ /* - * Copyright (c) 1995-1997, Index Data + * Copyright (c) 1995-1998, Index Data * See the file LICENSE for details. * Sebastian Hammer, Adam Dickmeiss * * $Log: tcpip.c,v $ - * Revision 1.19 1998-02-11 11:53:33 adam + * Revision 1.21 1998-05-20 09:55:32 adam + * Function tcpip_get treats EINPROGRESS error in the same way as + * EWOULDBLOCK. EINPROGRESS shouldn't be returned - but it is on + * Solaris in some cases. + * + * Revision 1.20 1998/05/18 10:10:40 adam + * Minor change to avoid C++ warning. + * + * Revision 1.19 1998/02/11 11:53:33 adam * Changed code so that it compiles as C++. * * Revision 1.18 1997/09/29 07:15:25 adam @@ -250,7 +258,7 @@ COMSTACK tcpip_type(int s, int blocking, int protocol) p->iofile = s; p->type = tcpip_type; - p->protocol = protocol; + p->protocol = (enum oid_proto) protocol; p->f_connect = tcpip_connect; p->f_rcvconnect = tcpip_rcvconnect; @@ -516,8 +524,12 @@ int tcpip_get(COMSTACK h, char **buf, int *bufsize) #ifdef WINDOWS if (WSAGetLastError() == WSAEWOULDBLOCK) #else +#ifdef EINPROGRESS + if (errno == EINPROGRESS || errno == EWOULDBLOCK) +#else if (errno == EWOULDBLOCK) #endif +#endif break; else return -1;