- m_socket->SetTimeout(m_timeout * 1000);
- m_socket->SetCallback(GSOCK_INPUT_FLAG | GSOCK_OUTPUT_FLAG |
- GSOCK_LOST_FLAG | GSOCK_CONNECTION_FLAG,
- wx_socket_callback, (char *)this);
-
- // If wait == false, then the call should be nonblocking.
- // When we are finished, we put the socket to blocking mode
- // again.
-
- if (!wait)
- m_socket->SetNonBlocking(1);
-
- // Reuse makes sense for clients too, if we are trying to rebind to the same port
- if (GetFlags() & wxSOCKET_REUSEADDR)
- {
- m_socket->SetReusable();
- }
- if (GetFlags() & wxSOCKET_BROADCAST)
- {
- m_socket->SetBroadcast();
- }
- if (GetFlags() & wxSOCKET_NOBIND)
- {
- m_socket->DontDoBind();
- }
-
- // If no local address was passed and one has been set, use the one that was Set
- if (!local && m_localAddress.GetAddress())
- {
- local = &m_localAddress;
- }
-
- // Bind to the local IP address and port, when provided
- if (local)
- {
- GAddress* la = local->GetAddress();
+ // If no local address was passed and one has been set, use the one that was Set
+ if (!local && m_localAddress.GetAddress())
+ {
+ local = &m_localAddress;
+ }