[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference jamin::pathworks32

Title:Digital PATHWORKS 32
Moderator:SPELNK::curless
Created:Fri Nov 01 1996
Last Modified:Fri Jun 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:337
Total number of notes:1612

253.0. "NT/WinSock2: question on shutdown()" by EDSCLU::JAYAKUMAR () Fri Apr 25 1997 17:42

Hi,

Can someone pls, share with me as to what is the expected behaviour of 
shutdown() ?

My understanding was, when shutdown(fd, SD_BOTH) is issued on a connected
socket (TCP or DECnet), it not only prohibits any more send()s or recv()s on
that socket but also completes any outstanding recv()s with an appropriate
error code. But now I am not sure.

In my appl. I am seeing that, issuing a shutdown(fd, SD_BOTH) on a DECnet
socket does not complete an outstanding WSARecv(). Unfortunately I can't get
this thing checked out in TCP since my application does not have an outstanding
WSARecv() with TCP.

What is the correct behaviour. Should I expect (or not expect) an outstanding
WSARecv() to complete on a shutdown()?

Thanks in advance
-Jay
T.RTitleUserPersonal
Name
DateLines
253.1EDSCLU::JAYAKUMARTue Apr 29 1997 13:5211
I was replied, offline by mail, that shutdown() only disallows future sends and
receives and does not complete a pending receive. Thanks.

I still trying to figure out if this is in any way different from other socket
implementations: such as TCP/Winsock2, Digital Unix socket and VMS/UCX sockets.

Writing portable applications, isn't as easy as it seems :-)

Thanks
-Jay