[Libreoffice-commits] core.git: framework/source

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Wed Apr 22 07:39:24 UTC 2020


 framework/source/uielement/togglebuttontoolbarcontroller.cxx |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

New commits:
commit f8156f7e81145cbf1c287058039ae70585cf64e7
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Tue Apr 21 12:11:10 2020 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Wed Apr 22 09:38:48 2020 +0200

    seems a poor idea to increment a vector iter by COMBOBOX_APPEND
    
    which is SAL_MAX_INT32, in the (presumably never happens) fallback case
    
    Change-Id: If425c6ce1bd9937ba2b26f6c68231640a2f13273
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92626
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/framework/source/uielement/togglebuttontoolbarcontroller.cxx b/framework/source/uielement/togglebuttontoolbarcontroller.cxx
index ca2d4312c443..0f0e341d1448 100644
--- a/framework/source/uielement/togglebuttontoolbarcontroller.cxx
+++ b/framework/source/uielement/togglebuttontoolbarcontroller.cxx
@@ -22,7 +22,6 @@
 #include <vcl/svapp.hxx>
 #include <vcl/toolbox.hxx>
 #include <vcl/menu.hxx>
-#include <vcl/combobox.hxx>
 
 using namespace ::com::sun::star;
 using namespace ::com::sun::star::awt;
@@ -184,8 +183,8 @@ void ToggleButtonToolbarController::executeControlCommand( const css::frame::Con
     }
     else if ( rControlCommand.Command == "InsertEntry" )
     {
-        sal_Int32      nPos( COMBOBOX_APPEND );
-        sal_Int32      nSize = sal_Int32( m_aDropdownMenuList.size() );
+        sal_Int32 nPos(0);
+        sal_Int32 nSize = sal_Int32( m_aDropdownMenuList.size() );
         OUString  aText;
         for ( sal_Int32 i = 0; i < rControlCommand.Arguments.getLength(); i++ )
         {


More information about the Libreoffice-commits mailing list