Closes the read-half, write-half or both read and write of a connection.
| Item | Description |
|---|---|
| so | The socket to which the shutdown will be issued. |
| how | 0 read, 1 write, 2 read and write |
The kern_soshutdown kernel service closes the read-half, write-half or both read and write of a connection.
The kern_soshutdown kernel service can be called from the process environment.
ksocket_t so;
/* Create the socket so */
kern_socreate(AF_INET, &so, SOCK_STREAM, IPPROTO_TCP);
/* Shutting down both the read/write */
kern_soshutdown(so, 2);
| Item | Description |
|---|---|
| 0 | Upon Success |
| >0 | Error |