Kaydet (Commit) 77508eee authored tarafından Caolán McNamara's avatar Caolán McNamara

fix assert seen on opening attachment from tdf#123163

I imagine it should have been seqPos-(idPos+2)

seems to be like this since the initial commit of

commit 091fe76b
Date:   Tue Jun 30 12:55:18 2015 +0300

    tdf#87348 implement mso-next-textbox vml-style textbox chaining import

Change-Id: Ic2f527ede2102c01c8589d58d8c705d59b0a6ffe
Reviewed-on: https://gerrit.libreoffice.org/67450Reviewed-by: 's avatarJustin Luth <justin_luth@sil.org>
Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
üst 98c0b208
...@@ -367,7 +367,8 @@ Reference< XShape > ShapeBase::convertAndInsert( const Reference< XShapes >& rxS ...@@ -367,7 +367,8 @@ Reference< XShape > ShapeBase::convertAndInsert( const Reference< XShapes >& rxS
sal_Int32 seqPos = sLinkChainName.indexOf("_s",idPos); sal_Int32 seqPos = sLinkChainName.indexOf("_s",idPos);
if (idPos < seqPos) if (idPos < seqPos)
{ {
id = sLinkChainName.copy(idPos+2,seqPos-idPos+2).toInt32(); auto idPosEnd = idPos+2;
id = sLinkChainName.copy(idPosEnd, seqPos - idPosEnd).toInt32();
seq = sLinkChainName.copy(seqPos+2).toInt32(); seq = sLinkChainName.copy(seqPos+2).toInt32();
} }
} }
......
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