vibe.d beta banner
get vibe.d
0.10.0

Asynchronous I/O that doesn’t get in your way, written in D

Function EventDriverSockets.cancelConnectStream

Aborts asynchronous connect by closing the socket.

abstract void cancelConnectStream (
  StreamSocketFD sock
) nothrow @safe;

This function may only invoked if the connection state is ConnectionState.connecting. It will cancel the connection attempt and guarantees that the connection callback will not be invoked in the future.

Note that upon completion, the socket handle will be invalid, regardless of the number of calls to addRef, and must not be used for further operations.

Parameters

NameDescription
sock Handle of the socket that is currently establishing a connection
Authors
Copyright
License