lotuswordpro/source/filter/lwpdrawobj.cxx | 2 ++ 1 file changed, 2 insertions(+)
New commits: commit 80570ddd00d47c70f57896b6495a9fd569a960d1 Author: Caolán McNamara <[email protected]> AuthorDate: Wed Jan 12 09:51:30 2022 +0000 Commit: Christian Lohmaier <[email protected]> CommitDate: Wed Jan 12 19:58:19 2022 +0100 ofz#43551 Use-of-uninitialized-value Change-Id: I2eb139f3bff296cff7d8f0e9a05f19df56b27ecd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128327 Reviewed-by: Michael Stahl <[email protected]> Tested-by: Jenkins diff --git a/lotuswordpro/source/filter/lwpdrawobj.cxx b/lotuswordpro/source/filter/lwpdrawobj.cxx index ac0c9879e18b..04acb795e631 100644 --- a/lotuswordpro/source/filter/lwpdrawobj.cxx +++ b/lotuswordpro/source/filter/lwpdrawobj.cxx @@ -1024,6 +1024,7 @@ void LwpDrawTextBox::Read() m_pStream->ReadInt16( m_aTextRec.nTextHeight ); m_pStream->ReadBytes(m_aTextRec.tmpTextFaceName, DRAW_FACESIZE); + m_aTextRec.tmpTextFaceName[DRAW_FACESIZE - 1] = 0; m_pStream->SeekRel(1);// PitchAndFamily m_pStream->ReadInt16( m_aTextRec.nTextSize ); @@ -1223,6 +1224,7 @@ void LwpDrawTextArt::Read() m_pStream->SeekRel(1); m_pStream->ReadBytes(m_aTextArtRec.tmpTextFaceName, DRAW_FACESIZE); + m_aTextArtRec.tmpTextFaceName[DRAW_FACESIZE - 1] = 0; m_pStream->SeekRel(1);// PitchAndFamily m_pStream->ReadInt16( m_aTextArtRec.nTextSize );
