[Libreoffice-commits] .: 5 commits - chart2/source svtools/inc svtools/source

Tor Lillqvist tml at kemper.freedesktop.org
Thu Mar 1 13:15:41 PST 2012


 chart2/source/tools/NameContainer.cxx      |    2 
 svtools/inc/svtools/addresstemplate.hxx    |    2 
 svtools/inc/svtools/brwbox.hxx             |    2 
 svtools/inc/svtools/calendar.hxx           |    2 
 svtools/inc/svtools/filechangedchecker.hxx |    2 
 svtools/inc/svtools/filectrl.hxx           |    2 
 svtools/inc/svtools/prnsetup.hxx           |    2 
 svtools/inc/svtools/svlbox.hxx             |    8 +--
 svtools/inc/svtools/svmedit.hxx            |    2 
 svtools/inc/svtools/svtabbx.hxx            |    4 -
 svtools/inc/svtools/taskbar.hxx            |    2 
 svtools/inc/svtools/templdlg.hxx           |   12 ++---
 svtools/inc/svtools/texteng.hxx            |    2 
 svtools/inc/svtools/valueset.hxx           |    2 
 svtools/inc/svtools/wizardmachine.hxx      |    6 +-
 svtools/source/edit/syntaxhighlight.cxx    |    2 
 svtools/source/filter/ixbm/xbmread.cxx     |   64 ++++++++++++++---------------
 17 files changed, 59 insertions(+), 59 deletions(-)

New commits:
commit 780f5bf5b177f93c8fd9ebd7ff1a322885074c8c
Author: Tor Lillqvist <tml at iki.fi>
Date:   Thu Mar 1 23:09:42 2012 +0200

    Presumably the intent is to zero the whole pHexTable, not just the 1st element

diff --git a/svtools/source/filter/ixbm/xbmread.cxx b/svtools/source/filter/ixbm/xbmread.cxx
index 6a8c2ee..84a8b02 100644
--- a/svtools/source/filter/ixbm/xbmread.cxx
+++ b/svtools/source/filter/ixbm/xbmread.cxx
@@ -65,7 +65,7 @@ XBMReader::~XBMReader()
 
 void XBMReader::InitTable()
 {
-    memset( pHexTable, 0, sizeof( short ) );
+    memset( pHexTable, 0, sizeof( short ) * 256 );
 
     pHexTable[(int)'0'] = 0;
     pHexTable[(int)'1'] = 1;
commit 2b26a54ecb589a67ee199759936a1adce148671a
Author: Tor Lillqvist <tml at iki.fi>
Date:   Thu Mar 1 23:06:58 2012 +0200

    Sillyish clang WaE: array subscript is of type 'char'

diff --git a/svtools/source/filter/ixbm/xbmread.cxx b/svtools/source/filter/ixbm/xbmread.cxx
index e6fc446..6a8c2ee 100644
--- a/svtools/source/filter/ixbm/xbmread.cxx
+++ b/svtools/source/filter/ixbm/xbmread.cxx
@@ -67,36 +67,36 @@ void XBMReader::InitTable()
 {
     memset( pHexTable, 0, sizeof( short ) );
 
-    pHexTable['0'] = 0;
-    pHexTable['1'] = 1;
-    pHexTable['2'] = 2;
-    pHexTable['3'] = 3;
-    pHexTable['4'] = 4;
-    pHexTable['5'] = 5;
-    pHexTable['6'] = 6;
-    pHexTable['7'] = 7;
-    pHexTable['8'] = 8;
-    pHexTable['9'] = 9;
-    pHexTable['A'] = 10;
-    pHexTable['B'] = 11;
-    pHexTable['C'] = 12;
-    pHexTable['D'] = 13;
-    pHexTable['E'] = 14;
-    pHexTable['F'] = 15;
-    pHexTable['X'] = 0;
-    pHexTable['a'] = 10;
-    pHexTable['b'] = 11;
-    pHexTable['c'] = 12;
-    pHexTable['d'] = 13;
-    pHexTable['e'] = 14;
-    pHexTable['f'] = 15;
-    pHexTable['x'] = 0;
-    pHexTable[' '] =     -1;
-    pHexTable[','] = -1;
-    pHexTable['}'] = -1;
-    pHexTable['\n'] = -1;
-    pHexTable['\t'] = -1;
-    pHexTable['\0'] = -1;
+    pHexTable[(int)'0'] = 0;
+    pHexTable[(int)'1'] = 1;
+    pHexTable[(int)'2'] = 2;
+    pHexTable[(int)'3'] = 3;
+    pHexTable[(int)'4'] = 4;
+    pHexTable[(int)'5'] = 5;
+    pHexTable[(int)'6'] = 6;
+    pHexTable[(int)'7'] = 7;
+    pHexTable[(int)'8'] = 8;
+    pHexTable[(int)'9'] = 9;
+    pHexTable[(int)'A'] = 10;
+    pHexTable[(int)'B'] = 11;
+    pHexTable[(int)'C'] = 12;
+    pHexTable[(int)'D'] = 13;
+    pHexTable[(int)'E'] = 14;
+    pHexTable[(int)'F'] = 15;
+    pHexTable[(int)'X'] = 0;
+    pHexTable[(int)'a'] = 10;
+    pHexTable[(int)'b'] = 11;
+    pHexTable[(int)'c'] = 12;
+    pHexTable[(int)'d'] = 13;
+    pHexTable[(int)'e'] = 14;
+    pHexTable[(int)'f'] = 15;
+    pHexTable[(int)'x'] = 0;
+    pHexTable[(int)' '] =     -1;
+    pHexTable[(int)','] = -1;
+    pHexTable[(int)'}'] = -1;
+    pHexTable[(int)'\n'] = -1;
+    pHexTable[(int)'\t'] = -1;
+    pHexTable[(int)'\0'] = -1;
 }
 
 // ------------------------------------------------------------------------
commit 68a571aeb5ea01fe2a10583c45efc109e8ae9968
Author: Tor Lillqvist <tml at iki.fi>
Date:   Thu Mar 1 23:02:30 2012 +0200

    WaE: equality comparison with extraneous parentheses

diff --git a/svtools/source/edit/syntaxhighlight.cxx b/svtools/source/edit/syntaxhighlight.cxx
index 0e5beff..d4caa88 100644
--- a/svtools/source/edit/syntaxhighlight.cxx
+++ b/svtools/source/edit/syntaxhighlight.cxx
@@ -477,7 +477,7 @@ sal_Bool SimpleTokenizer_Impl::getNextToken( /*out*/TokenTypes& reType,
             }
             reType = TT_PARAMETER;
         }
-        else if ((c=='-'))
+        else if (c=='-')
         {
             sal_Unicode cPeekNext = peekChar();
             if (cPeekNext=='-')
commit 8a83ce2e7e6950450b63a5f189a48c8a4820b6d1
Author: Tor Lillqvist <tml at iki.fi>
Date:   Thu Mar 1 23:00:49 2012 +0200

    More IMPL_LINK_NOARG fixes for clang

diff --git a/svtools/inc/svtools/addresstemplate.hxx b/svtools/inc/svtools/addresstemplate.hxx
index d69a765..7907408 100644
--- a/svtools/inc/svtools/addresstemplate.hxx
+++ b/svtools/inc/svtools/addresstemplate.hxx
@@ -149,7 +149,7 @@ namespace svt
         DECL_LINK(OnComboGetFocus, ComboBox*);
         DECL_LINK(OnComboLoseFocus, ComboBox*);
         DECL_LINK(OnComboSelect, ComboBox*);
-        DECL_LINK(OnOkClicked, Button*);
+        DECL_LINK(OnOkClicked, void*);
         DECL_LINK(OnDelayedInitialize, void*);
     };
 
diff --git a/svtools/inc/svtools/brwbox.hxx b/svtools/inc/svtools/brwbox.hxx
index 326d660..cc1b5b5 100644
--- a/svtools/inc/svtools/brwbox.hxx
+++ b/svtools/inc/svtools/brwbox.hxx
@@ -325,7 +325,7 @@ private:
     SVT_DLLPRIVATE void            ColumnInserted( sal_uInt16 nPos );
 
     DECL_DLLPRIVATE_LINK(       ScrollHdl, ScrollBar * );
-    DECL_DLLPRIVATE_LINK(       EndScrollHdl, ScrollBar * );
+    DECL_DLLPRIVATE_LINK(       EndScrollHdl, void * );
     DECL_DLLPRIVATE_LINK(       StartDragHdl, HeaderBar * );
 
     SVT_DLLPRIVATE long            GetFrozenWidth() const;
diff --git a/svtools/inc/svtools/calendar.hxx b/svtools/inc/svtools/calendar.hxx
index 9395b0a..94a7f5e 100644
--- a/svtools/inc/svtools/calendar.hxx
+++ b/svtools/inc/svtools/calendar.hxx
@@ -434,7 +434,7 @@ private:
 #ifdef _SV_CALENDAR_CXX
                         DECL_DLLPRIVATE_LINK( ImplSelectHdl, Calendar* );
                         DECL_DLLPRIVATE_LINK( ImplClickHdl, PushButton* );
-                        DECL_DLLPRIVATE_LINK( ImplPopupModeEndHdl, FloatingWindow* );
+                        DECL_DLLPRIVATE_LINK( ImplPopupModeEndHdl, void* );
 #endif
 
 public:
diff --git a/svtools/inc/svtools/filechangedchecker.hxx b/svtools/inc/svtools/filechangedchecker.hxx
index fe5fd68..5f6d03f 100644
--- a/svtools/inc/svtools/filechangedchecker.hxx
+++ b/svtools/inc/svtools/filechangedchecker.hxx
@@ -43,7 +43,7 @@ private :
     ::boost::function0<void> mpCallback;
 
     bool SVT_DLLPRIVATE getCurrentModTime(TimeValue& o_rValue) const;
-    DECL_LINK(TimerHandler, Timer *);
+    DECL_LINK(TimerHandler, void *);
 
 public :
     void resetTimer();
diff --git a/svtools/inc/svtools/filectrl.hxx b/svtools/inc/svtools/filectrl.hxx
index 9e5b3dc..14dcc75 100644
--- a/svtools/inc/svtools/filectrl.hxx
+++ b/svtools/inc/svtools/filectrl.hxx
@@ -70,7 +70,7 @@ protected:
     SVT_DLLPRIVATE void     GetFocus();
     SVT_DLLPRIVATE void     StateChanged( StateChangedType nType );
     SVT_DLLPRIVATE WinBits  ImplInitStyle( WinBits nStyle );
-    DECL_DLLPRIVATE_LINK( ButtonHdl, PushButton* );
+    DECL_DLLPRIVATE_LINK( ButtonHdl, void* );
 
 public:
                     FileControl( Window* pParent, WinBits nStyle, FileControlMode = 0 );
diff --git a/svtools/inc/svtools/prnsetup.hxx b/svtools/inc/svtools/prnsetup.hxx
index 4fc096c..7f366aa 100644
--- a/svtools/inc/svtools/prnsetup.hxx
+++ b/svtools/inc/svtools/prnsetup.hxx
@@ -75,7 +75,7 @@ private:
                     DECL_DLLPRIVATE_LINK( ImplPropertiesHdl, void* );
                     DECL_DLLPRIVATE_LINK( ImplOptionsHdl, void* );
                     DECL_DLLPRIVATE_LINK( ImplChangePrinterHdl, void* );
-                    DECL_DLLPRIVATE_LINK( ImplStatusHdl, Timer* );
+                    DECL_DLLPRIVATE_LINK( ImplStatusHdl, void* );
 
 public:
                     PrinterSetupDialog( Window* pWindow );
diff --git a/svtools/inc/svtools/svlbox.hxx b/svtools/inc/svtools/svlbox.hxx
index b4f33c1..3d1f6a6 100644
--- a/svtools/inc/svtools/svlbox.hxx
+++ b/svtools/inc/svtools/svlbox.hxx
@@ -266,7 +266,7 @@ class SVT_DLLPUBLIC SvLBox
 {
     friend class SvLBoxEntry;
 
-    DECL_DLLPRIVATE_LINK( TextEditEndedHdl_Impl, SvInplaceEdit2 * );
+    DECL_DLLPRIVATE_LINK( TextEditEndedHdl_Impl, void * );
     // Handler, der von TreeList zum Clonen eines Entries aufgerufen wird
     DECL_DLLPRIVATE_LINK( CloneHdl_Impl, SvListEntry* );
 
@@ -592,9 +592,9 @@ class SvInplaceEdit2
     sal_Bool        bMultiLine;
 
     void        CallCallBackHdl_Impl();
-    DECL_LINK( Timeout_Impl, Timer * );
-    DECL_LINK( ReturnHdl_Impl, Accelerator * );
-    DECL_LINK( EscapeHdl_Impl, Accelerator * );
+    DECL_LINK( Timeout_Impl, void * );
+    DECL_LINK( ReturnHdl_Impl, void * );
+    DECL_LINK( EscapeHdl_Impl, void * );
 
 public:
                 SvInplaceEdit2( Window* pParent, const Point& rPos, const Size& rSize,
diff --git a/svtools/inc/svtools/svmedit.hxx b/svtools/inc/svtools/svmedit.hxx
index bfce316..ffa5443 100644
--- a/svtools/inc/svtools/svmedit.hxx
+++ b/svtools/inc/svtools/svmedit.hxx
@@ -54,7 +54,7 @@ private:
 
 protected:
 
-    DECL_LINK(      ImpUpdateDataHdl, Timer* );
+    DECL_LINK(      ImpUpdateDataHdl, void* );
     void            StateChanged( StateChangedType nType );
     void            DataChanged( const DataChangedEvent& rDCEvt );
     virtual long    PreNotify( NotifyEvent& rNEvt );
diff --git a/svtools/inc/svtools/svtabbx.hxx b/svtools/inc/svtools/svtabbx.hxx
index 38aa9c0..99fdba2 100644
--- a/svtools/inc/svtools/svtabbx.hxx
+++ b/svtools/inc/svtools/svtabbx.hxx
@@ -147,8 +147,8 @@ private:
     ::svt::IAccessibleTabListBox*   m_pAccessible;
     AccessibleChildren              m_aAccessibleChildren;
 
-    DECL_DLLPRIVATE_LINK( ScrollHdl_Impl, SvTabListBox* );
-    DECL_DLLPRIVATE_LINK( CreateAccessibleHdl_Impl, HeaderBar* );
+    DECL_DLLPRIVATE_LINK( ScrollHdl_Impl, void* );
+    DECL_DLLPRIVATE_LINK( CreateAccessibleHdl_Impl, void* );
 
     void            RecalculateAccessibleChildren();
 
diff --git a/svtools/inc/svtools/taskbar.hxx b/svtools/inc/svtools/taskbar.hxx
index c776e0d..a303949 100644
--- a/svtools/inc/svtools/taskbar.hxx
+++ b/svtools/inc/svtools/taskbar.hxx
@@ -290,7 +290,7 @@ private:
     SVT_DLLPRIVATE ImplTaskSBFldItem*  ImplGetFieldItem( const Point& rPos, sal_Bool& rFieldRect ) const;
     SVT_DLLPRIVATE sal_Bool                ImplUpdateClock();
     SVT_DLLPRIVATE sal_Bool                ImplUpdateFlashItems();
-                        DECL_DLLPRIVATE_LINK( ImplTimerHdl, Timer* );
+                        DECL_DLLPRIVATE_LINK( ImplTimerHdl, void* );
 #endif
 
 public:
diff --git a/svtools/inc/svtools/templdlg.hxx b/svtools/inc/svtools/templdlg.hxx
index 4765dbb..f259515 100644
--- a/svtools/inc/svtools/templdlg.hxx
+++ b/svtools/inc/svtools/templdlg.hxx
@@ -54,14 +54,14 @@ private:
 
     SvtTmplDlg_Impl*    pImpl;
 
-    DECL_DLLPRIVATE_LINK(           SelectHdl_Impl, SvtTemplateWindow* );
-    DECL_DLLPRIVATE_LINK(           DoubleClickHdl_Impl, SvtTemplateWindow* );
-    DECL_DLLPRIVATE_LINK(           NewFolderHdl_Impl, SvtTemplateWindow* );
-    DECL_DLLPRIVATE_LINK(           SendFocusHdl_Impl, SvtTemplateWindow* );
+    DECL_DLLPRIVATE_LINK(           SelectHdl_Impl, void* );
+    DECL_DLLPRIVATE_LINK(           DoubleClickHdl_Impl, void* );
+    DECL_DLLPRIVATE_LINK(           NewFolderHdl_Impl, void* );
+    DECL_DLLPRIVATE_LINK(           SendFocusHdl_Impl, void* );
     DECL_DLLPRIVATE_LINK(           OKHdl_Impl, PushButton* );
-    DECL_DLLPRIVATE_LINK(           OrganizerHdl_Impl, PushButton* );
+    DECL_DLLPRIVATE_LINK(           OrganizerHdl_Impl, void* );
     DECL_DLLPRIVATE_LINK(           UpdateHdl_Impl, Timer* );
-    DECL_DLLPRIVATE_LINK(           OpenLinkHdl_Impl, svt::FixedHyperlink* );
+    DECL_DLLPRIVATE_LINK(           OpenLinkHdl_Impl, void* );
 
 public:
     SvtDocumentTemplateDialog( Window* pParent );
diff --git a/svtools/inc/svtools/texteng.hxx b/svtools/inc/svtools/texteng.hxx
index e9f0b6c..ab897b2 100644
--- a/svtools/inc/svtools/texteng.hxx
+++ b/svtools/inc/svtools/texteng.hxx
@@ -179,7 +179,7 @@ protected:
     void                ImpTextHeightChanged();
     void                ImpTextFormatted();
 
-    DECL_LINK(          IdleFormatHdl, Timer * );
+    DECL_LINK(          IdleFormatHdl, void * );
     void                CheckIdleFormatter();
     void                IdleFormatAndUpdate( TextView* pCurView = 0, sal_uInt16 nMaxTimerRestarts = 5 );
 
diff --git a/svtools/inc/svtools/valueset.hxx b/svtools/inc/svtools/valueset.hxx
index 059cdf2..7e0b7db 100644
--- a/svtools/inc/svtools/valueset.hxx
+++ b/svtools/inc/svtools/valueset.hxx
@@ -275,7 +275,7 @@ private:
     SVT_DLLPRIVATE void         ImplTracking( const Point& rPos, bool bRepeat );
     SVT_DLLPRIVATE void         ImplEndTracking( const Point& rPos, bool bCancel );
     DECL_DLLPRIVATE_LINK( ImplScrollHdl, ScrollBar* );
-    DECL_DLLPRIVATE_LINK( ImplTimerHdl, Timer* );
+    DECL_DLLPRIVATE_LINK( ImplTimerHdl, void* );
 #endif
 
     // Forbidden and not implemented.
diff --git a/svtools/inc/svtools/wizardmachine.hxx b/svtools/inc/svtools/wizardmachine.hxx
index 9627f4e..8700bf4 100644
--- a/svtools/inc/svtools/wizardmachine.hxx
+++ b/svtools/inc/svtools/wizardmachine.hxx
@@ -354,9 +354,9 @@ namespace svt
 
     private:
        // long OnNextPage( PushButton* );
-        DECL_DLLPRIVATE_LINK(OnNextPage, PushButton*);
-        DECL_DLLPRIVATE_LINK(OnPrevPage, PushButton*);
-        DECL_DLLPRIVATE_LINK(OnFinish, PushButton*);
+        DECL_DLLPRIVATE_LINK(OnNextPage, void*);
+        DECL_DLLPRIVATE_LINK(OnPrevPage, void*);
+        DECL_DLLPRIVATE_LINK(OnFinish, void*);
 
         SVT_DLLPRIVATE void     implResetDefault(Window* _pWindow);
         SVT_DLLPRIVATE void     implUpdateTitle();
commit c1efe33b99436d740b67a09538efe2676f3b9974
Author: Tor Lillqvist <tml at iki.fi>
Date:   Thu Mar 1 22:44:22 2012 +0200

    Presumably && is what we want here and not (pointlessly) a comma operator

diff --git a/chart2/source/tools/NameContainer.cxx b/chart2/source/tools/NameContainer.cxx
index d1ed4b0..a0d2a4f 100644
--- a/chart2/source/tools/NameContainer.cxx
+++ b/chart2/source/tools/NameContainer.cxx
@@ -152,7 +152,7 @@ Sequence< OUString > SAL_CALL NameContainer::getElementNames()
     sal_Int32 nCount = m_aMap.size();
     Sequence< OUString > aSeq(nCount);
     sal_Int32 nN = 0;
-    for( tContentMap::iterator aIter = m_aMap.begin(); aIter != m_aMap.end(), nN < nCount; ++aIter, ++nN )
+    for( tContentMap::iterator aIter = m_aMap.begin(); aIter != m_aMap.end() && nN < nCount; ++aIter, ++nN )
         aSeq[nN]=aIter->first;
     return aSeq;
 }


More information about the Libreoffice-commits mailing list