[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677

darin darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 07:31:47 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit 44e914ba7251035c7ec8dca54a4f8fe246ad3f03
Author: darin <darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Mar 27 00:13:16 2003 +0000

            Reviewed by Trey.
    
            - fixed a storage leak when running cvs-base
    
            * khtml/rendering/render_list.h: Added _markerInstalledInParent.
            * khtml/rendering/render_list.cpp:
            (RenderListItem::setStyle): Set _markerInstalledInParent to false when
            creating a new marker.
            (RenderListItem::detach): Detach the marker if it's not not installed in the
            parent yet.
            (RenderListItem::updateMarkerLocation): Set _markerInstalledInParent to true
            when installing the marker in a parent.
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@3929 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog-2003-10-25 b/WebCore/ChangeLog-2003-10-25
index 49bd168..33a98f6 100644
--- a/WebCore/ChangeLog-2003-10-25
+++ b/WebCore/ChangeLog-2003-10-25
@@ -1,3 +1,18 @@
+2003-03-26  Darin Adler  <darin at apple.com>
+
+        Reviewed by Trey.
+
+        - fixed a storage leak when running cvs-base
+
+        * khtml/rendering/render_list.h: Added _markerInstalledInParent.
+        * khtml/rendering/render_list.cpp:
+        (RenderListItem::setStyle): Set _markerInstalledInParent to false when
+        creating a new marker.
+        (RenderListItem::detach): Detach the marker if it's not not installed in the
+        parent yet.
+        (RenderListItem::updateMarkerLocation): Set _markerInstalledInParent to true
+        when installing the marker in a parent.
+
 2003-03-26  David Hyatt  <hyatt at apple.com>
 
 	Make <label> use tag list 1.  Fixes 3206063.  Residual style
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 49bd168..33a98f6 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,18 @@
+2003-03-26  Darin Adler  <darin at apple.com>
+
+        Reviewed by Trey.
+
+        - fixed a storage leak when running cvs-base
+
+        * khtml/rendering/render_list.h: Added _markerInstalledInParent.
+        * khtml/rendering/render_list.cpp:
+        (RenderListItem::setStyle): Set _markerInstalledInParent to false when
+        creating a new marker.
+        (RenderListItem::detach): Detach the marker if it's not not installed in the
+        parent yet.
+        (RenderListItem::updateMarkerLocation): Set _markerInstalledInParent to true
+        when installing the marker in a parent.
+
 2003-03-26  David Hyatt  <hyatt at apple.com>
 
 	Make <label> use tag list 1.  Fixes 3206063.  Residual style
diff --git a/WebCore/khtml/rendering/render_list.cpp b/WebCore/khtml/rendering/render_list.cpp
index dc87128..283a4de 100644
--- a/WebCore/khtml/rendering/render_list.cpp
+++ b/WebCore/khtml/rendering/render_list.cpp
@@ -143,6 +143,7 @@ void RenderListItem::setStyle(RenderStyle *_style)
         m_marker = new (renderArena()) RenderListMarker();
         m_marker->setStyle(newStyle);
         m_marker->setListItem(this);
+        _markerInstalledInParent = false;
     } else if ( m_marker && style()->listStyleType() == LNONE) {
         m_marker->detach(renderArena());
         m_marker = 0;
@@ -158,6 +159,15 @@ RenderListItem::~RenderListItem()
 {
 }
 
+void RenderListItem::detach(RenderArena* renderArena)
+{    
+    if (m_marker && !_markerInstalledInParent) {
+        m_marker->detach(renderArena);
+        m_marker = 0;
+    }
+    RenderBlock::detach(renderArena);
+}
+
 void RenderListItem::calcListValue()
 {
     // only called from the marker so..
@@ -236,6 +246,7 @@ void RenderListItem::updateMarkerLocation()
             if (!lineBoxParent)
                 lineBoxParent = this;
             lineBoxParent->addChild(m_marker, lineBoxParent->firstChild());
+            _markerInstalledInParent = true;
             if (!m_marker->minMaxKnown())
                 m_marker->calcMinMaxWidth();
             recalcMinMaxWidths();
diff --git a/WebCore/khtml/rendering/render_list.h b/WebCore/khtml/rendering/render_list.h
index 2a45352..e53b893 100644
--- a/WebCore/khtml/rendering/render_list.h
+++ b/WebCore/khtml/rendering/render_list.h
@@ -83,6 +83,8 @@ class RenderListItem : public RenderBlock
 public:
     RenderListItem(DOM::NodeImpl*);
     virtual ~RenderListItem();
+    
+    virtual void detach(RenderArena *);
 
     virtual const char *renderName() const { return "RenderListItem"; }
 
@@ -111,6 +113,7 @@ protected:
     long int predefVal;
     RenderListMarker *m_marker;
     bool _notInList;
+    bool _markerInstalledInParent;
 };
 
 }; //namespace

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list