class ClientSocket: public Socket
{
public:
- /** Emitted when the socket finishes connecting. The argument is a
- platform-dependent error code. */
- sigc::signal<void, int> signal_connect_finished;
+ /** Emitted when the socket finishes connecting. */
+ sigc::signal<void, const std::exception *> signal_connect_finished;
protected:
bool connecting;
connecting = false;
connected = (err==0);
- signal_connect_finished.emit(err);
+ if(err)
+ {
+ system_error exc("connect", err);
+ signal_connect_finished.emit(&exc);
+ }
+ else
+ signal_connect_finished.emit(0);
if(err!=0)
{