the peer, or -1 on error
Socket.receiveWithBlocking
ptrdiff_t receiveWithBlocking(ref ubyte[] buffer, bool blocking, gio.cancellable.Cancellable cancellable = null)This behaves exactly the same as gio.socket.Socket.receive, except that the choice of blocking or non-blocking behavior is determined by the blocking argument rather than by socket's properties.
Parameters
buffer | a buffer to read data into (which should be at least size bytes long). |
blocking | whether to do blocking or non-blocking I/O |
cancellable | a gio.cancellable.Cancellable or null |
Returns
Number of bytes read, or 0 if the connection was closed by