Kaydet (Commit) 6340daac authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Revert broken loplugin:sequentialassign change

Reverting part of 1123a47c
"loplugin:sequentialassign in sw" that had caused e.g. CppunitTest_chart2_export
to fail in UBSan builds like

> /sw/source/core/layout/frmtool.cxx:3540:77: runtime error: signed integer overflow: -47572123069180 * -47572123069180 cannot be represented in type 'long'
>     #0 0x2b44b168eeaf in GetFrameOfModify(SwRootFrame const*, SwModify const&, SwFrameType, SwPosition const*, std::pair<Point, bool> const*) /sw/source/core/layout/frmtool.cxx:3540:77
>     #1 0x2b44b07eb3f0 in SwContentNode::FindLayoutRect(bool, Point const*) const /sw/source/core/docnode/node.cxx:1169:60
>     #2 0x2b45266573da in AttributeOutputBase::TextFlyContent(SwFormatFlyCnt const&) /sw/source/filter/ww8/ww8atr.cxx:3229:34
>     #3 0x2b45265ecf49 in AttributeOutputBase::OutputItem(SfxPoolItem const&) /sw/source/filter/ww8/ww8atr.cxx:5258:13

(<https://ci.libreoffice.org/job/lo_ubsan/1236/>).

Change-Id: I580f6fb3fb2f561b1cf76f8cf113bfe20aead844
üst 8f13b0d3
......@@ -3225,7 +3225,8 @@ void AttributeOutputBase::TextFlyContent( const SwFormatFlyCnt& rFlyContent )
{
if ( auto pTextNd = dynamic_cast< const SwContentNode *>( GetExport().m_pOutFormatNode ) )
{
Point aLayPos = pTextNd->FindLayoutRect( false, &aLayPos ).Pos();
Point aLayPos;
aLayPos = pTextNd->FindLayoutRect( false, &aLayPos ).Pos();
SwPosition aPos( *pTextNd );
ww8::Frame aFrame( *rFlyContent.GetFrameFormat(), aPos );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment