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/+/138302
Tested-by: Jenkins
Reviewed-by: Justin Luth <jluth@mail.com>
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index 0a6b760..078d2aa 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -3728,10 +3728,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);
}