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

Stephan Bergmann sbergman at redhat.com
Wed Jul 13 15:58:00 UTC 2016


 cui/source/customize/cfg.cxx |    5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

New commits:
commit 8b04b9f4654bad5d1456576e68b25bd3510240d3
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Wed Jul 13 17:56:18 2016 +0200

    Remove wrong, needless downcast
    
    ...from SaveInData (which has a virtual dtor) to MenuSaveInData, while the data
    could also be ContextMenuSaveInData (not derived from MenuSavaInData).
    
    Change-Id: I4928fa97ed7738516699f8e57f354ef0f334c4f1

diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx
index 24bcca6..5595e6b 100644
--- a/cui/source/customize/cfg.cxx
+++ b/cui/source/customize/cfg.cxx
@@ -2502,10 +2502,7 @@ void SvxMenuConfigPage::dispose()
 {
     for ( sal_Int32 i = 0 ; i < m_pSaveInListBox->GetEntryCount(); ++i )
     {
-        MenuSaveInData* pData =
-            static_cast<MenuSaveInData*>(m_pSaveInListBox->GetEntryData( i ));
-
-        delete pData;
+        delete static_cast<SaveInData*>(m_pSaveInListBox->GetEntryData( i ));
     }
     m_pSaveInListBox->Clear();
 


More information about the Libreoffice-commits mailing list