From 1f2d3b3f09d16033dae1f99f7739564a5f4c5482 Mon Sep 17 00:00:00 2001 From: Mike Kaganski Date: Sun, 2 Dec 2018 00:59:58 +0300 Subject: tdf#120703 PVS: V560 A part of conditional expression is always true/false Change-Id: Ia9c496ec93bedb13764969bf21c3f21d84caacef Reviewed-on: https://gerrit.libreoffice.org/64413 Tested-by: Jenkins Reviewed-by: Mike Kaganski --- basic/source/sbx/sbxform.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'basic') diff --git a/basic/source/sbx/sbxform.cxx b/basic/source/sbx/sbxform.cxx index 45a88b556546..ce394fa903b3 100644 --- a/basic/source/sbx/sbxform.cxx +++ b/basic/source/sbx/sbxform.cxx @@ -647,7 +647,7 @@ void SbxBasicFormater::ScanFormatString( double dNumber, // Remark: in Visual-Basic the first 0 turns on the 0 for // all the following # (up to the decimal point), // this behaviour is simulated here with the flag. - if( bGenerateThousandSeparator && ( c=='0' || nMaxDigit >= nDigitPos ) && nDigitPos > 0 && (nDigitPos % 3 == 0) ) + if (bGenerateThousandSeparator && c == '0' && nDigitPos > 0 && (nDigitPos % 3 == 0)) { sReturnStrg.append(cThousandSep); } -- cgit