extensions/source/ole/servprov.cxx | 12 +++++++----- rsc/source/rscpp/cpp5.c | 2 +- sw/source/core/bastyp/calc.cxx | 4 ++-- vcl/source/fontsubset/sft.cxx | 2 +- vcl/source/gdi/sallayout.cxx | 6 +++--- 5 files changed, 14 insertions(+), 12 deletions(-)
New commits: commit 5f64aba978b117eb4372fef913823243a800fbea Author: Caolán McNamara <caol...@redhat.com> Date: Sat Oct 24 12:43:28 2015 +0100 cppcheck: invalidPrintfArgType_sint Change-Id: I4103c8e1549db44055fbfcb8ced6ec36d27fc126 diff --git a/rsc/source/rscpp/cpp5.c b/rsc/source/rscpp/cpp5.c index 499219b..1f73ff3 100644 --- a/rsc/source/rscpp/cpp5.c +++ b/rsc/source/rscpp/cpp5.c @@ -241,7 +241,7 @@ again: else { #ifdef DEBUG_EVAL - fprintf( pCppOut, "pushing %d onto value stack[%d]\n", + fprintf( pCppOut, "pushing %d onto value stack[%u]\n", evalue, valp - value); #endif *valp++ = evalue; diff --git a/sw/source/core/bastyp/calc.cxx b/sw/source/core/bastyp/calc.cxx index 7473c41..1f4dc62 100644 --- a/sw/source/core/bastyp/calc.cxx +++ b/sw/source/core/bastyp/calc.cxx @@ -1666,7 +1666,7 @@ void main() for( int n = 0; n < 27; ++n ) { - unsigned long ii = 0; + unsigned int ii = 0; const sal_Char* pp = sNTypeTab[ n ]; while( *pp ) @@ -1677,7 +1677,7 @@ void main() ch = aArr[ ii ] ? 'X' : ' '; aArr[ ii ] = 1; - printf( "%-20s -> %3d [%c]\n", sNTypeTab[ n ], ii, ch ); + printf( "%-20s -> %3u [%c]\n", sNTypeTab[ n ], ii, ch ); } } diff --git a/vcl/source/fontsubset/sft.cxx b/vcl/source/fontsubset/sft.cxx index 51f3f95..7461f56 100644 --- a/vcl/source/fontsubset/sft.cxx +++ b/vcl/source/fontsubset/sft.cxx @@ -2343,7 +2343,7 @@ int CreateT42FromTTGlyphs(TrueTypeFont *ttf, fprintf(outf, " 0 1 255 {Encoding exch /.notdef put} for\n"); for (i = 1; i<nGlyphs; i++) { - fprintf(outf, "Encoding %d /glyph%d put\n", encoding[i], gID[i]); + fprintf(outf, "Encoding %d /glyph%u put\n", encoding[i], gID[i]); } fprintf(outf, "/XUID [103 0 1 16#%08X %d 16#%08X 16#%08X] def\n", (unsigned int)rtl_crc32(0, ttf->ptr, ttf->fsize), (unsigned int)nGlyphs, (unsigned int)rtl_crc32(0, glyphArray, nGlyphs * 2), (unsigned int)rtl_crc32(0, encoding, nGlyphs)); diff --git a/vcl/source/gdi/sallayout.cxx b/vcl/source/gdi/sallayout.cxx index 6becfe7..e351deb 100644 --- a/vcl/source/gdi/sallayout.cxx +++ b/vcl/source/gdi/sallayout.cxx @@ -1624,7 +1624,7 @@ void MultiSalLayout::AdjustLayout( ImplLayoutArgs& rArgs ) nValid[ nLevel ] = mpLayouts[n]->GetNextGlyphs( 1, &nDummy, aPos, nStartNew[ nLevel ], &nGlyphAdv[ nLevel ], &nCharPos[ nLevel ] ); #ifdef MULTI_SL_DEBUG - if (nValid[nLevel]) fprintf(mslLog(), "layout[%d]->GetNextGlyphs %d,%d x%d a%d c%d %x\n", n, nStartOld[nLevel], nStartNew[nLevel], aPos.X(), (long)nGlyphAdv[nLevel], nCharPos[nLevel], + if (nValid[nLevel]) fprintf(mslLog(), "layout[%d]->GetNextGlyphs %d,%d x%d a%d c%ld %x\n", n, nStartOld[nLevel], nStartNew[nLevel], aPos.X(), (long)nGlyphAdv[nLevel], nCharPos[nLevel], rArgs.mrStr[nCharPos[nLevel]]); #endif if( (n > 0) && !nValid[ nLevel ] ) @@ -1695,7 +1695,7 @@ void MultiSalLayout::AdjustLayout( ImplLayoutArgs& rArgs ) nValid[0] = mpLayouts[0]->GetNextGlyphs( 1, &nDummy, aPos, nStartNew[0], &nGlyphAdv[0], &nCharPos[0] ); #ifdef MULTI_SL_DEBUG - if (nValid[0]) fprintf(mslLog(), "layout[0]->GetNextGlyphs %d,%d x%d a%d c%d %x\n", nStartOld[0], nStartNew[0], aPos.X(), (long)nGlyphAdv[0], nCharPos[0], rArgs.mrStr[nCharPos[0]]); + if (nValid[0]) fprintf(mslLog(), "layout[0]->GetNextGlyphs %d,%d x%d a%ld c%d %x\n", nStartOld[0], nStartNew[0], aPos.X(), (long)nGlyphAdv[0], nCharPos[0], rArgs.mrStr[nCharPos[0]]); #endif if( !nValid[0] ) break; @@ -1715,7 +1715,7 @@ void MultiSalLayout::AdjustLayout( ImplLayoutArgs& rArgs ) nValid[n] = mpLayouts[n]->GetNextGlyphs( 1, &nDummy, aPos, nStartNew[n], &nGlyphAdv[n], &nCharPos[n] ); #ifdef MULTI_SL_DEBUG - if (nValid[n]) fprintf(mslLog(), "layout[%d]->GetNextGlyphs %d,%d a%d c%d %x\n", n, nStartOld[n], nStartNew[n], (long)nGlyphAdv[n], nCharPos[n], rArgs.mrStr[nCharPos[n]]); + if (nValid[n]) fprintf(mslLog(), "layout[%d]->GetNextGlyphs %d,%d a%ld c%d %x\n", n, nStartOld[n], nStartNew[n], (long)nGlyphAdv[n], nCharPos[n], rArgs.mrStr[nCharPos[n]]); #endif // break after last glyph of active layout if( !nValid[n] ) commit 97839c6768f09684bfd0d39322896f65b68f8549 Author: Caolán McNamara <caol...@redhat.com> Date: Sat Oct 24 12:41:18 2015 +0100 bogus cppcheck duplicateExpressionTernary warning Change-Id: I9c6e7699790cc2e526a15daf8c5c25555aa30fc9 diff --git a/extensions/source/ole/servprov.cxx b/extensions/source/ole/servprov.cxx index 2467850..a38dd90 100644 --- a/extensions/source/ole/servprov.cxx +++ b/extensions/source/ole/servprov.cxx @@ -442,12 +442,14 @@ sal_Bool OleConverter_Impl2::supportsService(OUString const & ServiceName) css::uno::Sequence<OUString> OleConverter_Impl2::getSupportedServiceNames() throw (css::uno::RuntimeException, std::exception) { - return m_nUnoWrapperClass == INTERFACE_OLE_WRAPPER_IMPL - ? css::uno::Sequence<OUString>{ + if (m_nUnoWrapperClass == INTERFACE_OLE_WRAPPER_IMPL) + { + return css::uno::Sequence<OUString>{ "com.sun.star.bridge.OleBridgeSupplier2", - "com.sun.star.bridge.oleautomation.BridgeSupplier"} - : css::uno::Sequence<OUString>{ - "com.sun.star.bridge.OleBridgeSupplierVar1"}; + "com.sun.star.bridge.oleautomation.BridgeSupplier"}; + } + return css::uno::Sequence<OUString>{ + "com.sun.star.bridge.OleBridgeSupplierVar1"}; } // XInitialize ------------------------------------------------------------------------------
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits