]> git.mxchange.org Git - simgear.git/blobdiff - simgear/props/tiedpropertylist.hxx
Fixed a crash: the singleton needs to be instantiated the first time SGCommandMgr...
[simgear.git] / simgear / props / tiedpropertylist.hxx
index 647b8d5627eca1d216aeeb253b0d7dcb5407541d..39461afd5f836499478f4cd0a8d81cb0b32b3194 100644 (file)
@@ -37,11 +37,11 @@ public:
     virtual ~TiedPropertyList()
     { 
         _root = 0;
-        if (size()>0)
+        if (! empty())
         {
             SG_LOG(SG_GENERAL, SG_ALERT, "Detected properties with dangling ties. Use 'Untie' before removing a TiedPropertyList.");
             // running debug mode: go, fix it!
-            assert(size() == 0);
+            assert(empty());
         }
     }
 
@@ -124,7 +124,7 @@ public:
     }
 
     void Untie() {
-        while( size() > 0 ) {
+        while( ! empty() ) {
             SG_LOG( SG_GENERAL, SG_DEBUG, "untie of " << back()->getPath() );
             back()->untie();
             pop_back();