HP Rp7410 BSD Sockets Interface Programmer's Guide - Page 100
is executed on a socket, any
View all HP Rp7410 manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 100 highlights
Using Internet Datagram Sockets Closing a Socket Closing a Socket In most applications, you do not have to worry about cleaning up your sockets. When you exit your program and your process terminates, the sockets are closed for you. If you need to close a socket while your program is still running, use the HP-UX file system call close. You may have more than one process with the same socket descriptor if the process with the socket descriptor executes a fork. close decrements the file descriptor count and the calling process can no longer use that file descriptor. When the last close is executed on a socket, any unsent messages are sent and the socket is closed. Then the socket is destroyed and can no longer be used. For syntax and details on close, refer to the close(2) man page. 100 Chapter 4