[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - animations/source

Caolán McNamara caolanm at redhat.com
Thu Nov 7 16:23:53 CET 2013


 animations/source/animcore/animcore.cxx |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 8371cd6cee123d94b0b4b60b0d5b2d3795338fbe
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Nov 5 11:45:52 2013 +0000

    Resolves: fdo#69645 Parent Node disposed and mpParent pointing to junk
    
    mpParent points the contents of mxParent which is a WeakReference, so
    we can check if the WeakReference is still valid before using mpParent
    
    Change-Id: I40424714865e506b8cf27017539795eb834e10d2
    (cherry picked from commit 1563162131ae00cd2a33c59349567a7b820dc5db)
    Reviewed-on: https://gerrit.libreoffice.org/6584
    Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>
    Tested-by: Miklos Vajna <vmiklos at collabora.co.uk>

diff --git a/animations/source/animcore/animcore.cxx b/animations/source/animcore/animcore.cxx
index 5b83bc0..77e312f 100644
--- a/animations/source/animcore/animcore.cxx
+++ b/animations/source/animcore/animcore.cxx
@@ -2070,7 +2070,8 @@ void AnimationNode::fireChangeListener()
         }
     }
 
-    if( mpParent )
+    //fdo#69645 use get() on WeakReference of mxParent to test if mpParent is still valid
+    if( mpParent && mxParent.get().is() )
         mpParent->fireChangeListener();
 }
 


More information about the Libreoffice-commits mailing list