sw/source/filter/html/htmlgrin.cxx | 4 ++++ 1 file changed, 4 insertions(+)
New commits: commit ff2f33a9b9b2c4ca797193696d76c28344cee9f0 Author: Caolán McNamara <caol...@redhat.com> Date: Mon Dec 18 12:32:49 2017 +0000 ofz: reject graphics with bad anchors Change-Id: I9fc514f50843408981b53bdfb3131895b95e15eb Reviewed-on: https://gerrit.libreoffice.org/46712 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Caolán McNamara <caol...@redhat.com> Tested-by: Caolán McNamara <caol...@redhat.com> diff --git a/sw/source/filter/html/htmlgrin.cxx b/sw/source/filter/html/htmlgrin.cxx index 53842661bd95..53ec083588ce 100644 --- a/sw/source/filter/html/htmlgrin.cxx +++ b/sw/source/filter/html/htmlgrin.cxx @@ -715,6 +715,10 @@ IMAGE_SETEVENT: aFrameSize.SetHeightPercent( nPrcHeight ); aFrameSet.Put( aFrameSize ); + const SwNodeType eNodeType = m_pPam->GetNode().GetNodeType(); + if (eNodeType != SwNodeType::Text && eNodeType != SwNodeType::Table) + return; + // passing empty sGrfNm here, means we don't want the graphic to be linked SwFrameFormat *const pFlyFormat = m_xDoc->getIDocumentContentOperations().InsertGraphic(
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits