The netbuf_buf2sd function sends a buffer to a socket.
You can use this function to send data from IPC pipes to the client.
int netbuf_buf2sd(netbuf *buf, SYS_NETFD sd, int len);
The number of bytes transferred to the socket, if successful, or the
constant IO_ERROR if unsuccessful.
netbuf *buf is the buffer to send.
SYS_NETFD sd is the platform-independent
identifier of the socket.
int len is the length of the buffer.
netbuf_close() Function, netbuf_getc() Function, netbuf_getbytes() Function, netbuf_grab() Function, netbuf_open() Function