Read data from socket.
- Parameters:
-
| binary | data buffer pointer |
| sockfd | socket descriptor |
| nbytes | read size |
| timeoutms | wait timeout milliseconds |
- Returns:
- the length of data readed on success, or 0 on timeout, or -1 if an error(ex:socket closed) occurred.
- Since:
- 8.1R
- Note:
- does not need to set the socket as non-block mode.
Definition at line 180 of file qSocket.c.