X-Git-Url: http://jsfdemo.indexdata.com/?a=blobdiff_plain;ds=sidebyside;f=comstack%2Ftcpip.c;h=f65f2da9b58546294474f1cef0713e257bd704c5;hb=6a39772ad0cbd1bcb5d0984cd783d4a9e06bdfdb;hp=36cc696551b5af4acf6ef7a963757829826d993d;hpb=4519f45627820ab5acbb40400fc3667b08c140d3;p=yaz-moved-to-github.git diff --git a/comstack/tcpip.c b/comstack/tcpip.c index 36cc696..f65f2da 100644 --- a/comstack/tcpip.c +++ b/comstack/tcpip.c @@ -4,7 +4,10 @@ * Sebastian Hammer, Adam Dickmeiss * * $Log: tcpip.c,v $ - * Revision 1.23 1998-06-23 15:37:50 adam + * Revision 1.24 1998-06-29 07:59:17 adam + * Minor fix. + * + * Revision 1.23 1998/06/23 15:37:50 adam * Added type cast to prevent warning. * * Revision 1.22 1998/06/22 11:32:36 adam @@ -463,16 +466,17 @@ int tcpip_listen(COMSTACK h, char *raddr, int *addrlen, memcpy(raddr, &addr, *addrlen = sizeof(struct sockaddr_in)); else if (addrlen) *addrlen = 0; - -#if 1 if (check_ip && (*check_ip)(cd, (const char *) &addr.sin_addr, sizeof(addr.sin_addr), AF_INET)) { h->cerrno = CSDENY; - close (h->newfd); +#ifdef WINDOWS + closesocket(h->iofile); +#else + close(h->iofile); +#endif return -1; } -#endif h->state = CS_INCON; return 0; }