TODO: buffer == 0 -> fully unbuffered timeout == 0 -> fully blocking