[Orxonox-commit 2709] r7414 - code/branches/ipv6/src/libraries/network
adrfried at orxonox.net
adrfried at orxonox.net
Sat Sep 11 17:47:47 CEST 2010
Author: adrfried
Date: 2010-09-11 17:47:47 +0200 (Sat, 11 Sep 2010)
New Revision: 7414
Modified:
code/branches/ipv6/src/libraries/network/LANDiscoverable.cc
code/branches/ipv6/src/libraries/network/LANDiscovery.cc
Log:
some debug output fixed
Modified: code/branches/ipv6/src/libraries/network/LANDiscoverable.cc
===================================================================
--- code/branches/ipv6/src/libraries/network/LANDiscoverable.cc 2010-09-11 15:05:47 UTC (rev 7413)
+++ code/branches/ipv6/src/libraries/network/LANDiscoverable.cc 2010-09-11 15:47:47 UTC (rev 7414)
@@ -93,13 +93,15 @@
switch(event.type)
{
case ENET_EVENT_TYPE_CONNECT:
+ COUT(4) << "Received LAN discovery connect from client " << event.peer->host->receivedAddress << std::endl;
+ break;
case ENET_EVENT_TYPE_DISCONNECT:
case ENET_EVENT_TYPE_NONE:
break;
case ENET_EVENT_TYPE_RECEIVE:
if( strcmp( LAN_DISCOVERY_MESSAGE, (char*)event.packet->data ) == 0 ) // check for a suitable orxonox client
{
- COUT(4) << "Received LAN discovery message from " << event.peer->host << std::endl;
+ COUT(3) << "Received LAN discovery message from client " << event.peer->host->receivedAddress << std::endl;
packet::ServerInformation info;
info.setServerName("Orxonox Server");
info.send(event.peer);
Modified: code/branches/ipv6/src/libraries/network/LANDiscovery.cc
===================================================================
--- code/branches/ipv6/src/libraries/network/LANDiscovery.cc 2010-09-11 15:05:47 UTC (rev 7413)
+++ code/branches/ipv6/src/libraries/network/LANDiscovery.cc 2010-09-11 15:47:47 UTC (rev 7414)
@@ -79,7 +79,7 @@
{
case ENET_EVENT_TYPE_CONNECT:
{
- COUT(4) << "connect from server: " << event.peer->address << endl;
+ COUT(4) << "Received LAN discovery connect from server " << event.peer->host->receivedAddress << std::endl;
ENetPacket* packet = enet_packet_create(LAN_DISCOVERY_MESSAGE, strlen(LAN_DISCOVERY_MESSAGE)+1, ENET_PACKET_FLAG_RELIABLE);
enet_peer_send(event.peer, 0, packet);
break;
@@ -87,7 +87,7 @@
case ENET_EVENT_TYPE_RECEIVE:
{
packet::ServerInformation info(&event);
- COUT(3) << "received server information; Name: " << info.getServerName() << ", Address: " << info.getServerIP() << ", RTT: " << info.getServerRTT() << endl;
+ COUT(3) << "Received LAN discovery server information; Name: " << info.getServerName() << ", Address: " << info.getServerIP() << ", RTT: " << info.getServerRTT() << endl;
std::vector<packet::ServerInformation>::iterator it;
for( it=this->servers_.begin(); it!=this->servers_.end(); ++it )
{
More information about the Orxonox-commit
mailing list