[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    branches/KDE/4.3/kdelibs/khtml
From:       Maks Orlovich <maksim () kde ! org>
Date:       2009-09-19 17:59:57
Message-ID: 1253383197.996545.25992.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 1025797 by orlovich:

Fix crash in runAdFilter --- take in account that when we're removing a node its kids \
 will be removed as well...

BUG: 192308


 M  +5 -1      khtml_part.cpp  


--- branches/KDE/4.3/kdelibs/khtml/khtml_part.cpp #1025796:1025797
@@ -6576,7 +6576,11 @@
             {
                 if ( KHTMLGlobal::defaultHTMLSettings()->isAdFiltered( \
d->m_doc->completeURL( static_cast<ElementImpl \
*>(node)->getAttribute(ATTR_SRC).string() ) ) )  {
-                    // We found an IMG, IFRAME or INPUT (of type IMAGE) matching a \
filter. +                    // Since any kids of node will be deleted, too, \
fastforward nextNode +                    // until we get outside of node.
+                    while (nextNode && nextNode->isAncestor(node))
+                        nextNode = nextNode->traverseNextNode();
+
                     node->ref();
                     NodeImpl *parent = node->parent();
                     if( parent )


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic