cwSocket.cpp : Added more reporting from test callback.

This commit is contained in:
kpl 2020-03-18 16:03:12 -04:00
parent fe142ad7a8
commit de306242bb

View File

@ -1115,10 +1115,17 @@ namespace cw
rc_t rc; rc_t rc;
char addr[ INET_ADDRSTRLEN+1 ]; char addr[ INET_ADDRSTRLEN+1 ];
printf("type:%i user:%i conn:%i ", cbId, userId, connId );
if((rc = sock::addrToString( srcAddr, addr, INET_ADDRSTRLEN )) == kOkRC ) if((rc = sock::addrToString( srcAddr, addr, INET_ADDRSTRLEN )) == kOkRC )
{ {
printf("from user:%i conn:%i at %s : %s ", userId, connId, addr, (const char*)byteA ); printf("from %s ", addr );
} }
if( byteA != nullptr )
printf(" : %s ", (const char*)byteA);
printf("\n");
} }
} }