sw/source/filter/ww8/ww8par.cxx |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit ef5a7ab81cdee4c1e861d49ea79b6924a01a8792
Author:     Justin Luth <jl...@mail.com>
AuthorDate: Mon Aug 15 07:33:50 2022 -0400
Commit:     Michael Stahl <michael.st...@allotropia.de>
CommitDate: Fri Aug 19 11:31:49 2022 +0200

    fix tdf#77964 patch: don't change DefaultFormat
    
    I was actually making a chnage to the default frameformat
    instead of using a copy of it. Not at all intended.
    
    Change-Id: Idcb27eacd5b536914bc14d6086e730a42105ced3
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138429
    Tested-by: Jenkins
    Reviewed-by: Michael Stahl <michael.st...@allotropia.de>

diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index dd8484a389a8..a48893e8cc7a 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -3715,10 +3715,12 @@ bool SwWW8ImplReader::ReadChar(tools::Long nPosCp, 
tools::Long nCpOfs)
                         pResult = ImportOle();
                     else if (m_bSpec)
                     {
-                        SwFrameFormat* pAsCharFlyFormat = 
m_rDoc.GetDfltFrameFormat();
+                        SwFrameFormat* pAsCharFlyFormat =
+                            m_rDoc.MakeFrameFormat(OUString(), 
m_rDoc.GetDfltFrameFormat());
                         SwFormatAnchor aAnchor(RndStdIds::FLY_AS_CHAR);
                         pAsCharFlyFormat->SetFormatAttr(aAnchor);
                         pResult = ImportGraf(nullptr, pAsCharFlyFormat);
+                        m_rDoc.DelFrameFormat(pAsCharFlyFormat);
                     }
 
 

Reply via email to