AF_UNIX_CCSID address family sockets have the same specifications as AF_UNIX address family sockets. They can be used for connection-oriented or connectionless and provide communications on the same system.
Before working with AF_UNIX_CCSID socket application, you should be familiar with the Qlg_Path_Name_T structure to determine the output format.
When working with an output address structure, such as one returned from accept(), getsockname(), getpeername(), recvfrom(), and recvmsg(), the application must examine the socket address structure (sockaddr_unc) to determine its format. The sunc_format and sunc_qlg fields determine the output format of the path name. But sockets do not necessarily use the same values on output as the application used on input addresses.
The first example uses the following sequence of function calls:
AF_UNIX or AF_UNIX_CCSID are the only address families to support the socketpair() function. The socketpair() function returns two socket descriptors that are unnamed and connected.
The name space for UNIX domain sockets consists of path names. When a sockets program calls the bind() function, an entry is created in the file system directory. If the path name already exists, the bind() fails. Thus, a UNIX domain socket program should always call an unlink() functions to remove the directory entry when it ends.
The second example uses the following sequence of function calls:
AF_UNIX or AF_UNIX_CCSID are the only address families to support the socketpair() function. The socketpair() function returns two socket descriptors that are unnamed and connected.