Changeset 7809 in orxonox.OLD for branches/network/src
- Timestamp:
- May 24, 2006, 3:27:07 PM (19 years ago)
- Location:
- branches/network/src/lib/network
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/network/src/lib/network/network_stream.cc
r7806 r7809 390 390 for ( SynchronizeableList::iterator it = synchronizeables.begin(); it != synchronizeables.end(); it++ ) 391 391 { 392 PRINTF(0)("offset: %d\n", offset);393 392 int oldOffset = offset; 394 393 Synchronizeable & sync = **it; … … 427 426 assert( Converter::intToByteArray( n, buf + offset - n - INTSIZE, INTSIZE ) == INTSIZE ); 428 427 429 //check if all bytes == 0 -> remove data430 bool allZero = true;431 for ( int i = offset - n; i < offset; i++ )432 {433 if ( buf[i] != 0 )434 allZero = false;435 }436 437 if ( allZero )438 {439 NETPRINTF(n)("REMOVE ZERO DIFF: %s (%d)\n", sync.getClassName(), sync.getUniqueID());440 offset = oldOffset;441 }442 443 428 } 444 429 … … 449 434 peer->second.connectionMonitor->processUnzippedOutgoingPacket( buf, offset, currentState ); 450 435 451 assert( offset != 142 );452 436 NETPRINTF(n)("send packet: %d userId = %d\n", offset, peer->second.userId); 453 437 } … … 507 491 while ( offset + 2*INTSIZE < length ) 508 492 { 509 NETPRINTF(n)("%d\n", length - offset);493 assert( offset > 0 ); 510 494 assert( Converter::byteArrayToInt( buf + offset, &uniqueId ) == INTSIZE ); 511 495 offset += INTSIZE; … … 513 497 assert( Converter::byteArrayToInt( buf + offset, &syncDataLength ) == INTSIZE ); 514 498 offset += INTSIZE; 499 500 assert( syncDataLength > 0 ); 501 assert( syncDataLength < 1000 ); 515 502 516 503 Synchronizeable * sync = NULL; -
branches/network/src/lib/network/synchronizeable.cc
r7793 r7809 262 262 while ( it != recvStates[userId].end() && (*it)->stateId != fromStateId ) 263 263 it++; 264 264 265 265 266 // if ( getLeafClassID() == CL_SPACE_SHIP )
Note: See TracChangeset
for help on using the changeset viewer.