Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8297 for code/trunk


Ignore:
Timestamp:
Apr 22, 2011, 5:59:40 PM (14 years ago)
Author:
dafrick
Message:

Possible bug fix in PickupCarrier.

Location:
code/trunk/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/src/modules/designtools/ScreenshotManager.cc

    r8232 r8297  
    4141#include <OgreRoot.h>
    4242#include <OgreViewport.h>
    43 // #include <X11/Xlib.h> TODO: Needed?
    4443
    4544#include "core/ConfigValueIncludes.h"
     
    5352#include "graphics/Camera.h"
    5453
     54// #include <X11/Xlib.h> TODO: Needed?
     55
    5556namespace orxonox
    5657{
  • code/trunk/src/modules/designtools/SkyboxGenerator.cc

    r8234 r8297  
    3737#include <OgreRenderWindow.h>
    3838#include <OgreCamera.h>
    39 // #include <X11/Xlib.h> TODO: Needed?
    4039
    4140#include "util/ScopedSingletonManager.h"
     
    5352
    5453#include "ScreenshotManager.h"
     54
     55// #include <X11/Xlib.h> TODO: Needed?
    5556
    5657namespace orxonox
  • code/trunk/src/orxonox/interfaces/PickupCarrier.cc

    r7547 r8297  
    6666    {
    6767        std::set<Pickupable*>::iterator it = this->pickups_.begin();
    68         std::set<Pickupable*>::iterator temp;
     68        Pickupable* temp;
     69        // Iterate over all pickups that are attached to this PickupCarrier and destroy them.
    6970        while(it != this->pickups_.end())
    7071        {
     72            temp = *it;
    7173            (*it)->carrierDestroyed();
    72             temp = it;
    7374            it = this->pickups_.begin();
    74             if(it == temp) // Infinite loop avoidance, in case the pickup wasn't removed from the carrier somewhere in the carrierDestroy() procedure.
     75            if(temp == *it) // Infinite loop avoidance, in case the pickup wasn't removed from the carrier somewhere in the carrierDestroy() procedure.
    7576            {
    76                 COUT(2) << "Oops. In a PickupCarrier, while cleaning up, a Pickupable (&" << (*temp) << ") didn't unregister itself as it should have." << std::endl;;
     77                COUT(2) << "Oops. In a PickupCarrier, while cleaning up, a Pickupable (&" << temp << ") didn't unregister itself as it should have." << std::endl;;
    7778                it++;
    7879            }
Note: See TracChangeset for help on using the changeset viewer.