[Libreoffice-commits] core.git: Branch 'aoo/trunk' - sfx2/source

Armin Le Grand alg at apache.org
Tue Apr 15 03:07:43 PDT 2014


 sfx2/source/dialog/tabdlg.cxx |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 6abb7270a6cab2e3955e06b56dcf5d28becc7e18
Author: Armin Le Grand <alg at apache.org>
Date:   Tue Apr 15 09:20:07 2014 +0000

    i124638 As a first step, avoid crash when a TabPage is not found for a TabDialog, assert this

diff --git a/sfx2/source/dialog/tabdlg.cxx b/sfx2/source/dialog/tabdlg.cxx
index 78a0fd5..87eaecd 100644
--- a/sfx2/source/dialog/tabdlg.cxx
+++ b/sfx2/source/dialog/tabdlg.cxx
@@ -1406,10 +1406,11 @@ IMPL_LINK( SfxTabDialog, ActivatePageHdl, TabControl *, pTabCtrl )
     //UUUU fallback to 1st page when requested one does not exist
     if(!pDataObject && pTabCtrl->GetPageCount())
     {
+        OSL_ENSURE(false, "Requested TabPage not found in the TabDialog, fallback to 1st page (!)");
         pTabCtrl->SetCurPageId(pTabCtrl->GetPageId(0));
         nId = pTabCtrl->GetCurPageId();
         pTabPage = dynamic_cast< SfxTabPage* >(pTabCtrl->GetTabPage(nId));
-        Data_Impl* pDataObject = Find(*pImpl->pData, nId);
+        pDataObject = Find(*pImpl->pData, nId);
     }
 
     DBG_ASSERT( pDataObject, "Id nicht bekannt" );


More information about the Libreoffice-commits mailing list