]> git.saurik.com Git - wxWidgets.git/commitdiff
fixed my favorite bug (delete foo; call foo->Something())
authorVáclav Slavík <vslavik@fastmail.fm>
Wed, 29 Aug 2001 18:31:40 +0000 (18:31 +0000)
committerVáclav Slavík <vslavik@fastmail.fm>
Wed, 29 Aug 2001 18:31:40 +0000 (18:31 +0000)
 and non-recursive destructors as an add-on :)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@11513 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

contrib/src/xrc/xmlres.cpp
src/xrc/xmlres.cpp

index c5f7a8c8ed6fb771fcef1ca12d902ad66349c401..ef1e2f2761309e848237f3f6663dd6c66fe2b486 100644 (file)
@@ -245,14 +245,17 @@ static void ProcessPlatformProperty(wxXmlNode *node)
         }
 
         if (isok)
         }
 
         if (isok)
+        {
             ProcessPlatformProperty(c);
             ProcessPlatformProperty(c);
+            c = c->GetNext();
+        }
         else
         {
             node->RemoveChild(c);
         else
         {
             node->RemoveChild(c);
+            wxXmlNode *c2 = c->GetNext();
             delete c;
             delete c;
+            c = c2;
         }
         }
-
-        c = c->GetNext();
     }
 }
 
     }
 }
 
index c5f7a8c8ed6fb771fcef1ca12d902ad66349c401..ef1e2f2761309e848237f3f6663dd6c66fe2b486 100644 (file)
@@ -245,14 +245,17 @@ static void ProcessPlatformProperty(wxXmlNode *node)
         }
 
         if (isok)
         }
 
         if (isok)
+        {
             ProcessPlatformProperty(c);
             ProcessPlatformProperty(c);
+            c = c->GetNext();
+        }
         else
         {
             node->RemoveChild(c);
         else
         {
             node->RemoveChild(c);
+            wxXmlNode *c2 = c->GetNext();
             delete c;
             delete c;
+            c = c2;
         }
         }
-
-        c = c->GetNext();
     }
 }
 
     }
 }