scaddins/source/analysis/financial.cxx |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 57087dd1945429d9cfe6ce8bdc329ef315f455d3
Author:     Stephan Bergmann <sberg...@redhat.com>
AuthorDate: Tue Apr 26 14:46:44 2022 +0200
Commit:     Stephan Bergmann <sberg...@redhat.com>
CommitDate: Tue Apr 26 16:24:26 2022 +0200

    Pick better variable types
    
    Change-Id: Ia4ba19744e23c20d9b6fb0e9d803bc00b415191f
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133441
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <sberg...@redhat.com>

diff --git a/scaddins/source/analysis/financial.cxx 
b/scaddins/source/analysis/financial.cxx
index a10696bfdefb..5f40e86e38c8 100644
--- a/scaddins/source/analysis/financial.cxx
+++ b/scaddins/source/analysis/financial.cxx
@@ -584,16 +584,16 @@ double SAL_CALL AnalysisAddIn::getXnpv(
     aValList.Append( rValues );
     aDateList.Append( rDates );
 
-    sal_Int32           nNum = aValList.Count();
+    sal_uInt32          nNum = aValList.Count();
 
-    if( nNum != sal_Int32( aDateList.Count() ) || nNum < 2 )
+    if( nNum != aDateList.Count() || nNum < 2 )
         throw css::lang::IllegalArgumentException();
 
     double              fRet = 0.0;
     double              fNull = aDateList.Get( 0 );
     fRate++;
 
-    for( sal_Int32 i = 0 ; i < nNum ; i++ )
+    for( sal_uInt32 i = 0 ; i < nNum ; i++ )
         fRet += aValList.Get( i ) / ( pow( fRate, ( aDateList.Get( i ) - fNull 
) / 365.0 ) );
 
     RETURN_FINITE( fRet );

Reply via email to