socket_is_readable
- Синтаксис
-
native socket_is_readable(_socket, _timeout = 100000);
Переменная | Описание |
---|---|
_socket |
Socket descriptor |
_timeout |
Amount of time to block the call waiting for the socket to be marked as readable or for the timeout to expire, in µSeconds (1 sec = 1000000 µsec) |
- Описание
- Checks if a socket is marked as readable.
- Пометка
-
You can use this function to make sure there's something on the socket and avoid a blocking call.
- Пометка
-
Set _timeout to 0 avoid blocking the call.
- Пометка
-
A socket will become readable if there's any data or an EOF.
- Возвращает
- 1 if the socket is marked as readable 0 otherwise