Changeset 9460 in orxonox.OLD for branches/proxy/src/lib/network/udp_server_socket.cc
- Timestamp:
- Jul 25, 2006, 5:14:53 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/proxy/src/lib/network/udp_server_socket.cc
r9459 r9460 77 77 78 78 /** 79 * get newly connected socket. note79 * get newly connected client socket. note 80 80 * @return new socket or NULL if no new socket exists 81 * 82 * only clients connect to this socket 81 83 */ 82 84 NetworkSocket * UdpServerSocket::getNewClientSocket( void ) … … 93 95 return result; 94 96 } 97 98 99 /** 100 * get newly connected proxy socket. note 101 * @return new socket or NULL if no new socket exists 102 * 103 * only proxy servers connect to this socket 104 */ 105 NetworkSocket * UdpServerSocket::getNewProxySocket( void ) 106 { 107 NetworkSocket * result = NULL; 108 109 if ( newSocketList.size() > 0 ) 110 { 111 result = newSocketList.front(); 112 113 newSocketList.pop_front(); 114 } 115 116 return result; 117 } 118 119 95 120 96 121 /** … … 220 245 if ( !socket ) 221 246 return false; 222 247 223 248 assert( networkPacket.length <= UDP_PACKET_SIZE ); 224 249 … … 232 257 return false; 233 258 } 234 259 235 260 return true; 236 261 } … … 250 275 251 276 if ( packet->len <= 0 ) 252 continue; 253 277 continue; 278 254 279 for ( userId =0; userId < (int)userList.size(); userId++ ) 255 280 if ( userList[userId].addr.host == packet->address.host && userList[userId].addr.port == packet->address.port && userList[userId].randomByte == ( packet->data[0] & 0xFC ) )
Note: See TracChangeset
for help on using the changeset viewer.