scaddins/source/analysis/analysishelper.hxx |    1 +
 1 file changed, 1 insertion(+)

New commits:
commit 963255acd4cee20b861fe318667bfbb902e299af
Author:     Noel Grandin <noelgran...@gmail.com>
AuthorDate: Wed Oct 9 19:48:42 2024 +0200
Commit:     Noel Grandin <noel.gran...@collabora.co.uk>
CommitDate: Thu Oct 10 07:46:59 2024 +0200

    cid#1608078 Overflowed return value
    
    Change-Id: If654c8c86b71fdf1179f9ea89d31bf6b530e5046
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/174744
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>

diff --git a/scaddins/source/analysis/analysishelper.hxx 
b/scaddins/source/analysis/analysishelper.hxx
index 0fdae29ccd66..fdb5d4a7994a 100644
--- a/scaddins/source/analysis/analysishelper.hxx
+++ b/scaddins/source/analysis/analysishelper.hxx
@@ -580,6 +580,7 @@ inline sal_Int32 GetDiffDate360( const css::uno::Reference< 
css::beans::XPropert
 
 inline sal_Int16 GetDayOfWeek( sal_Int32 n )
 {   // monday = 0, ..., sunday = 6
+    assert(n >= 0);
     return static_cast< sal_Int16 >( ( n - 1 ) % 7 );
 }
 

Reply via email to