> The Pascal socket interface actually sends a "shuttingdown" signal to the > clients. NETSTAT CP EXT is ok for that. But who wants to write Pascal > code?
That's why you folks make the big bucks. Dirty deeds, done dirt cheap. 8-) > There's no provision for it in BSD sockets. Two implementation possibilities from the BSD socket world: MSG_OOB. Pending shutdown or other implementation-specific operation details are exactly what out-of-band messages are for (and in fact, there is direct precedent in that the TOPS-20 IP stack does in fact use OOB messages for signaling impending stack outage, as did the Xerox Dandelion and early 4.2BSD stack. I'd have to check, but I think the 4.3 stack still did, but not certain...8-)). You could also return ENETDOWN or better yet, EIO on connections that are pending shutdown. EIO is normally returned only for Unix-domain sockets, but there's no filesystem to generate errors from here, and it would logically map to the same function (in that there's an IUCV SEVER waiting in the wings once the stack is dead, so there would definitely be an I/O error in it's future...)