NetIPC 3000/XL Programmer's Reference Manual (5958-8600)
Table Of Contents
- 1 NetIPC Fundamentals
- 2 Cross-System NetIPC
- 3 NetIPC Intrinsics
- 4 NetIPC Examples
- A IPC Interpreter (IPCINT)
- B Cause and Diagnostic Codes
- C ErrorMessages
- D Migration From PTOP to NetIPC and RPM
- E C Program Language Considerations

Chapter 1 31
NetIPC Fundamentals
Using NetIPC for Interprocess Communication
Shutting Down Sockets and Connections
The NetIPC call IPCSHUTDOWN releases a descriptor and any resources
associated with it. IPCSHUTDOWN can be called to release a call socket
descriptor, a destination descriptor, or a VC socket descriptor. Because
system resources are being used whenever descriptors exist, you should
probably release them when they are no longer needed.
The call socket is needed as long as a process is expecting to receive a
connection request on that socket. A process which receives a connection
request can release the call socket any time after the IPCRECVCN
connection request, as long as no other connection requests are
expected for that call socket.
Similarly, a process which requests a connection can release its call
socket any time after the call to IPCCONNECT, as long as it is not
expecting to receive any more connection requests for that socket.
For TCP only, a process does not need to create a call socket (via
IPCCREATE) at all; instead, it can use a temporary call socket by calling
IPCCONNECT without specifying a call socket descriptor. (A temporary
call socket is automatically destroyed when the IPCCONNECT call
completes.) A process which requests a connection can also release the
destination socket any time after the call to IPCCONNECT.
For example, in the section “Establishing a Connection”, Process A no
longer needs the destination descriptor after calling IPCCONNECT and
can use IPCSHUTDOWN to release the destination descriptor. In addition,
if Process A does not expect to request additional connections, it can
also call IPCSHUTDOWN a second time to release the call socket.
Process B, as described in “Establishing a Connection”, can call
IPCSHUTDOWN to release its call socket any time after the call to
IPCRECVCN (see “Receiving a Connection Request”). Process B should
release its call socket only if it does not want to establish additional
connections.
Before a process terminates, it should terminate its virtual circuit
connections by releasing its VC sockets with IPCSHUTDOWN. If a process
does not release its VC sockets before terminating, the system releases
them when the process terminates. Because IPCSHUTDOWN takes effect
very quickly, all of the data that is in transit on the connection is lost
when the connection is shut down. As a result, if there is a possibility
that data is in transit on the connection, the processes that share a
connection must cooperate to ensure that no data is lost.
X.25 Access
X.25 direct access to level 3 does not support the graceful release bit.
Using IPCSHUTDOWN on a VC socket descriptor causes a clear packet to
be sent.