summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordinesh_mp <dinesh.patil@synerzip.com>2014-07-17 18:59:37 +0530
committerLuboš Luňák <l.lunak@collabora.com>2014-07-21 14:12:40 +0000
commitc73cb50cdd7dffe809d3e66e5acdfab2bd521f62 (patch)
tree9ebe26543b0acfd80ced06bfc6b0d3833ebe4d03
parent22274468ef27ae8651f8ea8805611bf39758b9d5 (diff)
fdo#81380: LO crashes while opening the document
LO crashes while opening the document because PropertySet interface is null and check for this condition was missing, so added the check. Change-Id: I04dd873ea0923a662e27f9eb2013cde31edc912b Reviewed-on: https://gerrit.libreoffice.org/10379 Reviewed-by: Luboš Luňák <l.lunak@collabora.com> Tested-by: Luboš Luňák <l.lunak@collabora.com>
-rw-r--r--sw/qa/core/data/ooxml/pass/fdo81380.docxbin0 -> 40040 bytes
-rw-r--r--writerfilter/source/dmapper/PropertyMap.cxx3
2 files changed, 2 insertions, 1 deletions
diff --git a/sw/qa/core/data/ooxml/pass/fdo81380.docx b/sw/qa/core/data/ooxml/pass/fdo81380.docx
new file mode 100644
index 000000000000..52458448fbc5
--- /dev/null
+++ b/sw/qa/core/data/ooxml/pass/fdo81380.docx
Binary files differ
diff --git a/writerfilter/source/dmapper/PropertyMap.cxx b/writerfilter/source/dmapper/PropertyMap.cxx
index f3d93f86db83..1fe256f1817f 100644
--- a/writerfilter/source/dmapper/PropertyMap.cxx
+++ b/writerfilter/source/dmapper/PropertyMap.cxx
@@ -549,7 +549,8 @@ void SectionPropertyMap::ApplyBorderToPageStyles(
sal_uInt32 nLineWidth = 0;
if (m_pBorderLines[nBorder])
nLineWidth = m_pBorderLines[nBorder]->LineWidth;
- SetBorderDistance( xFirst, aMarginIds[nBorder], aBorderDistanceIds[nBorder],
+ if(xFirst.is())
+ SetBorderDistance( xFirst, aMarginIds[nBorder], aBorderDistanceIds[nBorder],
m_nBorderDistances[nBorder], nOffsetFrom, nLineWidth );
if(xSecond.is())
SetBorderDistance( xSecond, aMarginIds[nBorder], aBorderDistanceIds[nBorder],