Changeset 405 for code/branches/FICN/src/network/PacketDecoder.cc
- Timestamp:
- Dec 5, 2007, 4:40:46 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/FICN/src/network/PacketDecoder.cc
r403 r405 121 121 memcpy( (void*)&(currentState->normsize), (const void*)(data+3*sizeof( int )), sizeof( int ) ); 122 122 //since data is not allocated, because it's just a pointer, allocate it with size of gamestatedatastream 123 currentState->data = (unsigned char*)(malloc( currentState-> size ));123 currentState->data = (unsigned char*)(malloc( currentState->compsize )); 124 124 //copy the GameStateCompressed data 125 125 memcpy( (void*)(currentState->data), (const void*)(data+4*sizeof( int )), currentState->compsize ); … … 186 186 { 187 187 cout << "id of GameStateCompressed: " << data->id << endl; 188 cout << "size of GameStateCompressed: " << data-> size << endl;188 cout << "size of GameStateCompressed: " << data->compsize << endl; 189 189 } 190 190
Note: See TracChangeset
for help on using the changeset viewer.