From 34d3f1601cf2dcb1c931d9454f2a06741f9e8b87 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Mon, 28 Feb 2022 12:01:05 +0000 Subject: cid#707500 Uninitialized scalar variable MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I4680b59483ae827cbceb567968dc6c4e864f7ad4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130702 Tested-by: Caolán McNamara Reviewed-by: Caolán McNamara --- basic/source/sbx/sbxdate.cxx | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'basic/source/sbx') diff --git a/basic/source/sbx/sbxdate.cxx b/basic/source/sbx/sbxdate.cxx index 6b695a9c40c7..057e16f09d03 100644 --- a/basic/source/sbx/sbxdate.cxx +++ b/basic/source/sbx/sbxdate.cxx @@ -84,14 +84,8 @@ double ImpGetDate( const SbxValues* p ) break; case SbxDECIMAL: case SbxBYREF | SbxDECIMAL: - if( p->pDecimal ) - { - p->pDecimal->getDouble( nRes ); - } - else - { + if (!p->pDecimal || !p->pDecimal->getDouble(nRes)) nRes = 0.0; - } break; case SbxBYREF | SbxSTRING: case SbxSTRING: -- cgit