summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2021-08-28 09:56:52 +0100
committerXisco Fauli <xiscofauli@libreoffice.org>2021-08-30 13:43:38 +0200
commit50c4082b4c71173badd7641ea9b87e2e8a08b62f (patch)
tree6ae96876ff87f675ee67cccf3fa169ca4ea83d9c
parent3bc4beb1254df9e68339aad6f4f9646f2c5a1b9f (diff)
ofz: MemorySanitizer: use-of-uninitialized-value
Change-Id: I649e8b8fa0d1752f0f4b0b6b688cea8ae945bb87 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121154 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de> Tested-by: Jenkins
-rw-r--r--sc/source/filter/lotus/lotimpop.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/sc/source/filter/lotus/lotimpop.cxx b/sc/source/filter/lotus/lotimpop.cxx
index 159b13786f6b..3970ac93a4d6 100644
--- a/sc/source/filter/lotus/lotimpop.cxx
+++ b/sc/source/filter/lotus/lotimpop.cxx
@@ -72,6 +72,9 @@ void ImportLotus::Bof()
Skip( 1 );
Read( nFlags );
+ if (!pIn->good())
+ return;
+
if( nFileSub == 0x0004 )
{
if( nFileCode == 0x1000 )
@@ -87,7 +90,7 @@ void ImportLotus::Bof()
bool ImportLotus::BofFm3()
{
- sal_uInt16 nFileCode, nFileSub;
+ sal_uInt16 nFileCode(0), nFileSub(0);
Read( nFileCode );
Read( nFileSub );