From: curt Date: Tue, 15 Sep 1998 02:10:03 +0000 (+0000) Subject: Temporary destructor patch until Steve can release next version of PUI. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=af80c5e018f082aca3b06a7771c4f85f1dc68b48;p=simgear.git Temporary destructor patch until Steve can release next version of PUI. --- diff --git a/PUI/puInterface.cxx b/PUI/puInterface.cxx index 4b996845..500f8297 100644 --- a/PUI/puInterface.cxx +++ b/PUI/puInterface.cxx @@ -253,10 +253,15 @@ void puInterface::doHit ( int, int, int, int ) puInterface::~puInterface () { - puPopLiveInterface () ; + puPopLiveInterface () ; - for ( puObject *bo = dlist ; bo != NULL ; bo = bo->next ) - delete bo ; + puObject *bo = dlist ; + + while ( bo != NULL ) { + puObject *tmp_bo = bo->next ; + delete bo ; + bo = tmp_bo ; + } }