Receive data (up to buffer.length
bytes) from a socket.
If address
is non-null then address
will be set equal to the source address
of the received packet. address
is owned by the caller.
See receive for additional information.
this |
a Socket |
address |
a pointer to a SocketAddress pointer, or null |
buffer |
a buffer to read data into (which should be at least |
cancellable |
a gcancellable or null |
size |
the number of bytes you want to read from the socket |
Number of bytes read, or 0 if the connection was closed by the peer, or -1 on error |