basic/source/runtime/methods.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 136688ce632fff0695608a2555d6a7d8c19bec2e
Author:     Simon Chenery <[email protected]>
AuthorDate: Sat Oct 4 21:01:41 2025 +0200
Commit:     Mike Kaganski <[email protected]>
CommitDate: Sun Oct 5 11:30:54 2025 +0200

    tdf#154285 Check too many arguments to BASIC SIN function
    
    Change-Id: I0b6aa9b39c62d906fcc2e627057dae07807a6b1a
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/191862
    Reviewed-by: Mike Kaganski <[email protected]>
    Tested-by: Jenkins

diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx
index 9fcff1df5e2c..6ba7c9acf03e 100644
--- a/basic/source/runtime/methods.cxx
+++ b/basic/source/runtime/methods.cxx
@@ -255,7 +255,7 @@ void SbRtl_Error(StarBASIC * pBasic, SbxArray & rPar, bool)
 
 void SbRtl_Sin(StarBASIC *, SbxArray & rPar, bool)
 {
-    if (rPar.Count() < 2)
+    if (rPar.Count() != 2)
         return StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
 
     SbxVariableRef pArg = rPar.Get(1);

Reply via email to