dbaccess/source/core/dataaccess/datasource.cxx |    1 +
 dbaccess/source/ui/app/AppController.cxx       |    8 +++++++-
 2 files changed, 8 insertions(+), 1 deletion(-)

New commits:
commit 7f3ab74eb62ec83d6fc4432979654944f27de7b4
Author:     Julien Nabet <serval2...@yahoo.fr>
AuthorDate: Thu Oct 19 11:13:59 2023 +0200
Commit:     Julien Nabet <serval2...@yahoo.fr>
CommitDate: Thu Oct 19 18:20:12 2023 +0200

    Related tdf#144256: missing removePropertyChangeListener calls in 
AppController
    
    Compare and use same order as in 
dbaccess/source/core/dataaccess/datasource.cxx
    
    Change-Id: Id025e6e801387c2c377af88d2816c68ed9183e55
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158171
    Tested-by: Julien Nabet <serval2...@yahoo.fr>
    Reviewed-by: Julien Nabet <serval2...@yahoo.fr>

diff --git a/dbaccess/source/core/dataaccess/datasource.cxx 
b/dbaccess/source/core/dataaccess/datasource.cxx
index 55c161b854d1..eaa580a3a66d 100644
--- a/dbaccess/source/core/dataaccess/datasource.cxx
+++ b/dbaccess/source/core/dataaccess/datasource.cxx
@@ -735,6 +735,7 @@ Reference< XPropertySetInfo >  
ODatabaseSource::getPropertySetInfo()
     return new ::cppu::OPropertyArrayHelper
     {
         {
+            // a change here means a change should also been done in 
OApplicationController::disposing()
             { PROPERTY_INFO, PROPERTY_ID_INFO, cppu::UnoType<Sequence< 
PropertyValue >>::get(), css::beans::PropertyAttribute::BOUND },
             { PROPERTY_ISPASSWORDREQUIRED, PROPERTY_ID_ISPASSWORDREQUIRED, 
cppu::UnoType<bool>::get(), css::beans::PropertyAttribute::BOUND },
             { PROPERTY_ISREADONLY, PROPERTY_ID_ISREADONLY, 
cppu::UnoType<bool>::get(), css::beans::PropertyAttribute::READONLY },
diff --git a/dbaccess/source/ui/app/AppController.cxx 
b/dbaccess/source/ui/app/AppController.cxx
index f9b818db663f..61c0940e98a1 100644
--- a/dbaccess/source/ui/app/AppController.cxx
+++ b/dbaccess/source/ui/app/AppController.cxx
@@ -327,14 +327,20 @@ void SAL_CALL OApplicationController::disposing()
 
         if ( m_xDataSource.is() )
         {
+            // Should correspond to ODatabaseSource::createArrayHelper in 
dbaccess/source/core/dataaccess/datasource.cxx
             m_xDataSource->removePropertyChangeListener(OUString(), this);
             m_xDataSource->removePropertyChangeListener(PROPERTY_INFO, this);
-            m_xDataSource->removePropertyChangeListener(PROPERTY_URL, this);
             
m_xDataSource->removePropertyChangeListener(PROPERTY_ISPASSWORDREQUIRED, this);
+            m_xDataSource->removePropertyChangeListener(PROPERTY_ISREADONLY, 
this);
             
m_xDataSource->removePropertyChangeListener(PROPERTY_LAYOUTINFORMATION, this);
+            m_xDataSource->removePropertyChangeListener(PROPERTY_NAME, this);
+            
m_xDataSource->removePropertyChangeListener(PROPERTY_NUMBERFORMATSSUPPLIER, 
this);
+            m_xDataSource->removePropertyChangeListener(PROPERTY_PASSWORD, 
this);
+            m_xDataSource->removePropertyChangeListener(PROPERTY_SETTINGS, 
this);
             
m_xDataSource->removePropertyChangeListener(PROPERTY_SUPPRESSVERSIONCL, this);
             m_xDataSource->removePropertyChangeListener(PROPERTY_TABLEFILTER, 
this);
             
m_xDataSource->removePropertyChangeListener(PROPERTY_TABLETYPEFILTER, this);
+            m_xDataSource->removePropertyChangeListener(PROPERTY_URL, this);
             m_xDataSource->removePropertyChangeListener(PROPERTY_USER, this);
             m_xDataSource = nullptr;
         }

Reply via email to