Date: prev next · Thread: first prev next last
2012 Archives by date, by thread · List index


On Wednesday 20 of June 2012, Miklos Vajna wrote:
 sw/source/core/doc/docfly.cxx |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 017a82c50c338a4304ca0b945ed04c7d2d62f1d5
Author: Miklos Vajna <vmiklos@suse.cz>
Date:   Wed Jun 20 13:24:17 2012 +0200

    SwDoc::SetFlyFrmAnchor: fix crash when SwTxtNode has no hints

    Change-Id: I5178ff1bbf1a3e8eebec10f44e74d9d0806d3168

diff --git a/sw/source/core/doc/docfly.cxx b/sw/source/core/doc/docfly.cxx
index e867da1..388f11d 100644
--- a/sw/source/core/doc/docfly.cxx
+++ b/sw/source/core/doc/docfly.cxx
@@ -261,7 +261,8 @@ sal_Int8 SwDoc::SetFlyFrmAnchor( SwFrmFmt& rFmt,
SfxItemSet& rSet, sal_Bool bNew "Missing FlyInCnt-Hint." );
         OSL_ENSURE( pHnt && pHnt->GetFlyCnt().GetFrmFmt() == &rFmt,
                     "Wrong TxtFlyCnt-Hint." );
-        const_cast<SwFmtFlyCnt&>(pHnt->GetFlyCnt()).SetFlyFmt();
+        if (pHnt)
+            const_cast<SwFmtFlyCnt&>(pHnt->GetFlyCnt()).SetFlyFmt();

 I think this is a sign of internal inconsistency. I had a similar problem 
leading to 5de61f7a4ddb502730454e4bf3232f7f4b4175e1 .

-- 
 Lubos Lunak
 l.lunak@suse.cz

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.