[Libreoffice-commits] core.git: svx/source

Lionel Elie Mamane lionel at mamane.lu
Tue Jun 24 10:16:28 PDT 2014


 svx/source/form/formcontroller.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 402e0c0a679dd4da2b1767d959be9aa364c1878d
Author: Lionel Elie Mamane <lionel at mamane.lu>
Date:   Tue Jun 24 19:09:48 2014 +0200

    fdo#75339 object comparison by reference, not pointer
    
    Reference<>::operator== ensures that the comparison is done right.
    ::get may return different raw pointers for the same object,
    yielding false positives.
    
    Although the same end effect is reached by
      commit	f8115ce72dad45b82b044d9c8f5c253d0514574d
      author	Stephan Bergmann <sbergman at redhat.com>	2014-06-24 09:40:23 (GMT)
      fdo#75339: Substituting XInterface* eq. for object eq. requires queryInterface
    
    This way is more robust against future "clean-up"s.
    
    Change-Id: I2f3c63ac577152c666554b78b88d3779dabe4d45

diff --git a/svx/source/form/formcontroller.cxx b/svx/source/form/formcontroller.cxx
index 6660be4..e46897a 100644
--- a/svx/source/form/formcontroller.cxx
+++ b/svx/source/form/formcontroller.cxx
@@ -308,7 +308,7 @@ namespace
     bool lcl_isBoundTo( const Reference< XPropertySet >& _rxControlModel, const Reference< XInterface >& _rxNormDBField )
     {
         Reference< XInterface > xNormBoundField( _rxControlModel->getPropertyValue( FM_PROP_BOUNDFIELD ), UNO_QUERY );
-        return ( xNormBoundField.get() == _rxNormDBField.get() );
+        return ( xNormBoundField == _rxNormDBField );
     }
 
     bool lcl_isInputRequired( const Reference< XPropertySet >& _rxControlModel )


More information about the Libreoffice-commits mailing list