From 2a4b8d63f26155d42f2ee512ccfa1cd0fbbaee91 Mon Sep 17 00:00:00 2001 From: "mkaply%us.ibm.com" Date: Wed, 4 Jul 2001 03:37:30 +0000 Subject: [PATCH] #88209 [s]r=tor xlib only - crash on ZDNet web benchmark git-svn-id: svn://10.0.0.236/trunk@98610 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/widget/src/xlib/nsWindow.cpp | 27 ++++++++++++++++----------- 1 file changed, 16 insertions(+), 11 deletions(-) diff --git a/mozilla/widget/src/xlib/nsWindow.cpp b/mozilla/widget/src/xlib/nsWindow.cpp index a04b1545626..058c8be614b 100644 --- a/mozilla/widget/src/xlib/nsWindow.cpp +++ b/mozilla/widget/src/xlib/nsWindow.cpp @@ -130,21 +130,26 @@ void nsWindow::UpdateIdle (void *data) { if (update_queue != nsnull) { - nsList *old_queue = update_queue; - nsListItem *tmp_list = old_queue->getHead(); + nsList *old_queue; + nsListItem *tmp_list; + old_queue = update_queue; update_queue = nsnull; - - if (tmp_list != nsnull) { - while (tmp_list != nsnull) - { - nsWindow *window = (nsWindow *)tmp_list->getData(); - window->Update(); - window->mIsUpdating = PR_FALSE; + + for( tmp_list = old_queue->getHead() ; tmp_list != nsnull ; tmp_list = tmp_list->getNext() ) + { + nsWindow *window = NS_STATIC_CAST(nsWindow*,(tmp_list->getData())); - tmp_list = tmp_list->getNext(); - } + window->mIsUpdating = PR_FALSE; } + + for( tmp_list = old_queue->getHead() ; tmp_list != nsnull ; tmp_list = tmp_list->getNext() ) + { + nsWindow *window = NS_STATIC_CAST(nsWindow*,(tmp_list->getData())); + + window->Update(); + } + delete old_queue; } }