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

pats pats at apache.org
Sun Nov 12 01:09:16 UTC 2017


 sfx2/source/appl/linkmgr2.cxx |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit c04136353ebde071d27697c953c791896beaaf9e
Author: pats <pats at apache.org>
Date:   Sun Nov 12 00:12:55 2017 +0000

    #127581# Writer crashes after copying all content

diff --git a/sfx2/source/appl/linkmgr2.cxx b/sfx2/source/appl/linkmgr2.cxx
index 80795e68b206..494f8c2019a1 100644
--- a/sfx2/source/appl/linkmgr2.cxx
+++ b/sfx2/source/appl/linkmgr2.cxx
@@ -159,9 +159,13 @@ sal_Bool LinkManager::Insert( SvBaseLink* pLink )
     SvBaseLinkRef* pTmp = new SvBaseLinkRef( pLink );
     pLink->SetLinkManager( this );
     aLinkTbl.Insert( pTmp, aLinkTbl.Count() );
-    Window *parent = GetPersist()->GetDialogParent();
     if (mAutoAskUpdateAllLinks)
     {
+        Window *parent = NULL;
+        SfxObjectShell* persist = GetPersist();
+        if (persist != NULL)
+            parent = GetPersist()->GetDialogParent();
+
         SetUserAllowsLinkUpdate(pLink, GetUserAllowsLinkUpdate(parent));
     }
 


More information about the Libreoffice-commits mailing list