[Libreoffice-commits] .: Branch 'libreoffice-3-4' - sw/source
Caolán McNamara
caolan at kemper.freedesktop.org
Thu Jun 2 03:58:46 PDT 2011
sw/source/core/frmedt/feshview.cxx | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
New commits:
commit 3860483d8cb9e259ca3f68347ba0e35f7bfb1739
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Jun 2 11:39:43 2011 +0100
Resolves: rhbz#710004 band-aid for immediate crash in IsAlignPossible
(cherry picked from commit d6839fa9aaac82892b5af2bc00c9ad196c9ff4bb)
diff --git a/sw/source/core/frmedt/feshview.cxx b/sw/source/core/frmedt/feshview.cxx
index ef9becd..87bc266 100644
--- a/sw/source/core/frmedt/feshview.cxx
+++ b/sw/source/core/frmedt/feshview.cxx
@@ -2566,8 +2566,9 @@ sal_Bool SwFEShell::IsAlignPossible() const
{
SdrObject *pO = Imp()->GetDrawView()->GetMarkedObjectList().GetMark(0)->GetMarkedSdrObj();
SwDrawContact *pC = (SwDrawContact*)GetUserCall(pO);
+ OSL_ENSURE( pC, "No SwDrawContact!");
//only as character bound drawings can be aligned
- bRet = (pC->GetFmt()->GetAnchor().GetAnchorId() == FLY_AS_CHAR);
+ bRet = pC ? (pC->GetFmt()->GetAnchor().GetAnchorId() == FLY_AS_CHAR) : sal_False;
}
if ( bRet )
return Imp()->GetDrawView()->IsAlignPossible();
More information about the Libreoffice-commits
mailing list