- if ( socket->m_takesEvents )
- return ;
-
- {
- OTResult state ;
- socket->m_takesEvents = TRUE ;
- state = OTGetEndpointState(socket->m_endpoint);
-
- {
- OTByteCount sz = 0 ;
- OTCountDataBytes( socket->m_endpoint , &sz ) ;
- if ( state == T_INCON || sz > 0 )
- {
- socket->m_detected |= GSOCK_INPUT_FLAG ;
- (socket->m_cbacks[GSOCK_INPUT])(socket, GSOCK_INPUT, socket->m_data[GSOCK_INPUT]);
- }
- }
- {
- if ( state == T_DATAXFER || state == T_INREL )
- {
- socket->m_detected |=GSOCK_OUTPUT_FLAG ;
- (socket->m_cbacks[GSOCK_OUTPUT])(socket, GSOCK_OUTPUT, socket->m_data[GSOCK_OUTPUT]);
- }
- }
- }
+ if ( m_takesEvents )
+ return ;
+
+ {
+ OTResult state ;
+ m_takesEvents = true ;
+ state = OTGetEndpointState(m_endpoint);
+
+ {
+ OTByteCount sz = 0 ;
+ OTCountDataBytes( m_endpoint , &sz ) ;
+ if ( state == T_INCON || sz > 0 )
+ {
+ m_detected |= GSOCK_INPUT_FLAG ;
+ (m_cbacks[GSOCK_INPUT])(this, GSOCK_INPUT, m_data[GSOCK_INPUT]);
+ }
+ }
+ {
+ if ( state == T_DATAXFER || state == T_INREL )
+ {
+ m_detected |=GSOCK_OUTPUT_FLAG ;
+ (m_cbacks[GSOCK_OUTPUT])(this, GSOCK_OUTPUT, m_data[GSOCK_OUTPUT]);
+ }
+ }
+ }