Back to FlowSsh Documentation

Client - Disconnect


void __cdecl FlowSshC_Client_SetDisconnectHandler(
  FlowSshC_Client* client,
  FlowSshC_DisconnectHandler handler,
  void* handlerData);


[Client] void Disconnect(RefPtr<ProgressHandler> const& progress);


[Client] public void Disconnect(ProgressHandler progress);


  • [C] client: FlowSshC_Client pointer.
  • [C] handler: A ProgressHandler function to be used with the request. Optional.
  • [C] handlerData: An application-defined value to be passed to the handler. Optional.
  • [Cpp/Net] progress: A ProgressHandler object to be used with the request. Optional.


Disconnects us from the server. The following rules apply:

  • Disconnect will fail (through its progress handler), if the client is already disconnecting.
  • Disconnecting an already disconnected client yields success.
  • If the client is connecting, then issuing a disconnect will abort the connection. In this case, the [Client]OnDisconnect handler is not called.
  • No other handlers will be called on the client after a successfully completed disconnect.