Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 7, 2008, 5:34:35 PM (16 years ago)
Author:
scheusso
Message:

fixed some memory leaks (not all though)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/network3/src/network/Client.cc

    r1245 r1246  
    235235        COUT(4) << "client tick: sending gs " << gs << std::endl;
    236236        if(client_connection.addPacket(pck_gen.gstate(gs)))
    237           if(!client_connection.sendPackets())
    238             COUT(3) << "Problem sending partial gamestate" << std::endl;
     237          COUT(3) << "Problem adding partial gamestate to queue" << std::endl;
    239238        // now delete it to save memory
    240239        delete [] gs->data;
     
    251250      }
    252251    }
     252    if(!client_connection.sendPackets())
     253      COUT(3) << "Problem sending packets to server" << std::endl;
    253254    return;
    254255  }
     
    260261      if(gamestate.pushGameState(data)){
    261262        client_connection.addPacket(pck_gen.acknowledgement(id));
    262         if(!client_connection.sendPackets())
    263           COUT(2) << "Could not send acknowledgment" << std::endl;
     263        // we do this at the end of a tick
     264//        if(!client_connection.sendPackets())
     265//          COUT(2) << "Could not send acknowledgment" << std::endl;
    264266      }
    265267//       test_once=true;
Note: See TracChangeset for help on using the changeset viewer.