[Orxonox-commit 3790] r8470 - code/trunk/src/orxonox/worldentities
rgrieder at orxonox.net
rgrieder at orxonox.net
Thu May 12 17:14:50 CEST 2011
Author: rgrieder
Date: 2011-05-12 17:14:49 +0200 (Thu, 12 May 2011)
New Revision: 8470
Modified:
code/trunk/src/orxonox/worldentities/SpaceBoundaries.cc
Log:
A classic fix ;)
Orxonox crashed on startup.
Modified: code/trunk/src/orxonox/worldentities/SpaceBoundaries.cc
===================================================================
--- code/trunk/src/orxonox/worldentities/SpaceBoundaries.cc 2011-05-12 14:50:23 UTC (rev 8469)
+++ code/trunk/src/orxonox/worldentities/SpaceBoundaries.cc 2011-05-12 15:14:49 UTC (rev 8470)
@@ -60,18 +60,21 @@
}
SpaceBoundaries::~SpaceBoundaries()
{
- delete this->centerRadar_;
+ if (this->isInitialized())
+ {
+ delete this->centerRadar_;
- this->pawnsIn_.clear();
+ this->pawnsIn_.clear();
- for( std::vector<billboardAdministration>::iterator current = this->billboards_.begin(); current != this->billboards_.end(); current++)
- {
- if( current->billy != NULL)
+ for( std::vector<billboardAdministration>::iterator current = this->billboards_.begin(); current != this->billboards_.end(); current++)
{
- delete current->billy;
+ if( current->billy != NULL)
+ {
+ delete current->billy;
+ }
}
+ this->billboards_.clear();
}
- this->billboards_.clear();
}
void SpaceBoundaries::checkWhoIsIn()
More information about the Orxonox-commit
mailing list