[Libreoffice-commits] core.git: 5 commits - odk/source sal/inc sc/source vcl/win winaccessibility/source xmlsecurity/source

Stephan Bergmann sbergman at redhat.com
Fri Dec 16 14:29:18 UTC 2016


 odk/source/unoapploader/win/unoapploader.c                            |    4 -
 sal/inc/rtllifecycle.h                                                |   24 +++++-----
 sc/source/ui/docshell/dataprovider.cxx                                |    2 
 vcl/win/gdi/salfont.cxx                                               |    1 
 winaccessibility/source/service/msaaservice_impl.cxx                  |    5 --
 xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.hxx |    2 
 xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx       |   12 ++---
 xmlsecurity/source/xmlsec/mscrypt/xmlsignature_mscryptimpl.cxx        |    8 +--
 8 files changed, 27 insertions(+), 31 deletions(-)

New commits:
commit 54c401d775c15e39d4939342ef2132132873ccf1
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Fri Dec 16 15:28:15 2016 +0100

    loplugin:staticmethods (clang-cl)
    
    Change-Id: Id97600a7d29fbe938d67ea074ca12dd665a29cc3

diff --git a/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.hxx b/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.hxx
index e439b44..5136db9 100644
--- a/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.hxx
+++ b/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.hxx
@@ -177,7 +177,7 @@ class SecurityEnvironment_MSCryptImpl : public ::cppu::WeakImplHelper<
 
         xmlSecKeysMngrPtr createKeysManager() throw( css::uno::Exception , css::uno::RuntimeException ) ;
 
-        void destroyKeysManager(xmlSecKeysMngrPtr pKeysMngr) throw( css::uno::Exception , css::uno::RuntimeException ) ;
+        static void destroyKeysManager(xmlSecKeysMngrPtr pKeysMngr) throw( css::uno::Exception , css::uno::RuntimeException ) ;
 } ;
 
 #endif // INCLUDED_XMLSECURITY_SOURCE_XMLSEC_MSCRYPT_SECURITYENVIRONMENT_MSCRYPTIMPL_HXX
diff --git a/xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx b/xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx
index 86cab56..7d5fd3e 100644
--- a/xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx
+++ b/xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx
@@ -157,7 +157,7 @@ SAL_CALL XMLEncryption_MSCryptImpl::encrypt(
     pEncCtx = xmlSecEncCtxCreate( pMngr ) ;
     if( pEncCtx == nullptr )
     {
-        pSecEnv->destroyKeysManager( pMngr );
+        SecurityEnvironment_MSCryptImpl::destroyKeysManager( pMngr );
         //throw XMLEncryptionException() ;
         clearErrorRecorder();
         return aTemplate;
@@ -167,13 +167,13 @@ SAL_CALL XMLEncryption_MSCryptImpl::encrypt(
     if( xmlSecEncCtxXmlEncrypt( pEncCtx , pEncryptedData , pContent ) < 0 ) {
         aTemplate->setStatus(css::xml::crypto::SecurityOperationStatus_UNKNOWN);
         xmlSecEncCtxDestroy( pEncCtx ) ;
-        pSecEnv->destroyKeysManager( pMngr );
+        SecurityEnvironment_MSCryptImpl::destroyKeysManager( pMngr );
         clearErrorRecorder();
         return aTemplate;
     }
     aTemplate->setStatus(css::xml::crypto::SecurityOperationStatus_OPERATION_SUCCEEDED);
     xmlSecEncCtxDestroy( pEncCtx ) ;
-    pSecEnv->destroyKeysManager( pMngr );
+    SecurityEnvironment_MSCryptImpl::destroyKeysManager( pMngr );
 
     //get the new EncryptedData element
     if (isParentRef)
@@ -263,7 +263,7 @@ XMLEncryption_MSCryptImpl::decrypt(
     pEncCtx = xmlSecEncCtxCreate( pMngr ) ;
     if( pEncCtx == nullptr )
     {
-        pSecEnv->destroyKeysManager( pMngr );
+        SecurityEnvironment_MSCryptImpl::destroyKeysManager( pMngr );
         //throw XMLEncryptionException() ;
         clearErrorRecorder();
         return aTemplate;
@@ -273,7 +273,7 @@ XMLEncryption_MSCryptImpl::decrypt(
     if( xmlSecEncCtxDecrypt( pEncCtx , pEncryptedData ) < 0 || pEncCtx->result == nullptr ) {
         aTemplate->setStatus(css::xml::crypto::SecurityOperationStatus_UNKNOWN);
         xmlSecEncCtxDestroy( pEncCtx ) ;
-        pSecEnv->destroyKeysManager( pMngr );
+        SecurityEnvironment_MSCryptImpl::destroyKeysManager( pMngr );
 
         //throw XMLEncryptionException() ;
         clearErrorRecorder();
@@ -306,7 +306,7 @@ XMLEncryption_MSCryptImpl::decrypt(
 
     //Destroy the encryption context
     xmlSecEncCtxDestroy( pEncCtx ) ;
-    pSecEnv->destroyKeysManager( pMngr );
+    SecurityEnvironment_MSCryptImpl::destroyKeysManager( pMngr );
 
     //get the decrypted element
     XMLElementWrapper_XmlSecImpl * ret = new XMLElementWrapper_XmlSecImpl(isParentRef?
diff --git a/xmlsecurity/source/xmlsec/mscrypt/xmlsignature_mscryptimpl.cxx b/xmlsecurity/source/xmlsec/mscrypt/xmlsignature_mscryptimpl.cxx
index abf01ac..ac5ffda 100644
--- a/xmlsecurity/source/xmlsec/mscrypt/xmlsignature_mscryptimpl.cxx
+++ b/xmlsecurity/source/xmlsec/mscrypt/xmlsignature_mscryptimpl.cxx
@@ -116,7 +116,7 @@ SAL_CALL XMLSignature_MSCryptImpl::generate(
     if( pDsigCtx == nullptr )
     {
         //throw XMLSignatureException() ;
-        pSecEnv->destroyKeysManager( pMngr );
+        SecurityEnvironment_MSCryptImpl::destroyKeysManager( pMngr );
         clearErrorRecorder();
         return aTemplate;
     }
@@ -136,7 +136,7 @@ SAL_CALL XMLSignature_MSCryptImpl::generate(
 
 
     xmlSecDSigCtxDestroy( pDsigCtx ) ;
-    pSecEnv->destroyKeysManager( pMngr );
+    SecurityEnvironment_MSCryptImpl::destroyKeysManager( pMngr );
 
     //Unregistered the stream/URI binding
     if( xUriBinding.is() )
@@ -212,7 +212,7 @@ SAL_CALL XMLSignature_MSCryptImpl::validate(
     pDsigCtx = xmlSecDSigCtxCreate( pMngr ) ;
     if( pDsigCtx == nullptr )
     {
-        pSecEnv->destroyKeysManager( pMngr );
+        SecurityEnvironment_MSCryptImpl::destroyKeysManager( pMngr );
         clearErrorRecorder();
         return aTemplate;
     }
@@ -253,7 +253,7 @@ SAL_CALL XMLSignature_MSCryptImpl::validate(
     }
 
     xmlSecDSigCtxDestroy( pDsigCtx ) ;
-    pSecEnv->destroyKeysManager( pMngr );
+    SecurityEnvironment_MSCryptImpl::destroyKeysManager( pMngr );
 
     //Unregistered the stream/URI binding
     if( xUriBinding.is() )
commit b2d800eda6189488485c7b5ac5759a89a2b4aa86
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Fri Dec 16 15:27:34 2016 +0100

    loplugin:unnecessaryoverride (clang-cl)
    
    Change-Id: Ib98620423606e355cf24ee3954f196d9f073c30d

diff --git a/winaccessibility/source/service/msaaservice_impl.cxx b/winaccessibility/source/service/msaaservice_impl.cxx
index 20cb117..943e70b 100644
--- a/winaccessibility/source/service/msaaservice_impl.cxx
+++ b/winaccessibility/source/service/msaaservice_impl.cxx
@@ -64,7 +64,6 @@ private:
 
 public:
     MSAAServiceImpl ();
-    virtual ~MSAAServiceImpl() override;
 
     // XComponent - as used by VCL to lifecycle manage this bridge.
     virtual void SAL_CALL dispose()
@@ -277,10 +276,6 @@ MSAAServiceImpl::MSAAServiceImpl()
         SAL_WARN( "iacc2", "No VCL toolkit interface to listen to for events");
 }
 
-MSAAServiceImpl::~MSAAServiceImpl()
-{
-}
-
 void MSAAServiceImpl::dispose()
     throw (css::uno::RuntimeException, std::exception)
 {
commit f1639ffe28865e584b42d8e652d7690a15f06297
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Fri Dec 16 15:27:05 2016 +0100

    -Werror,-Wunused-function (clang-cl)
    
    Change-Id: I19292f03c1a28eed8712dc83dc9cc0334c8f45e3

diff --git a/vcl/win/gdi/salfont.cxx b/vcl/win/gdi/salfont.cxx
index 8bf8c54..7c5fd4a 100644
--- a/vcl/win/gdi/salfont.cxx
+++ b/vcl/win/gdi/salfont.cxx
@@ -662,7 +662,6 @@ sal_IntPtr WinFontFace::GetFontId() const
     return mnId;
 }
 
-static unsigned GetUInt( const unsigned char* p ) { return((p[0]<<24)+(p[1]<<16)+(p[2]<<8)+p[3]);}
 static inline DWORD CalcTag( const char p[5]) { return (p[0]+(p[1]<<8)+(p[2]<<16)+(p[3]<<24)); }
 
 void WinFontFace::UpdateFromHDC( HDC hDC ) const
commit 5fbe5e968b866faab360327b00487b0d59cdd4f4
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Fri Dec 16 15:26:09 2016 +0100

    Work around -Werror,-Wunused-macros (clang-cl)
    
    Change-Id: Iebe340f9594f0e1847055361cebce5930685efd9

diff --git a/sc/source/ui/docshell/dataprovider.cxx b/sc/source/ui/docshell/dataprovider.cxx
index 76f3776..9b4fba3 100644
--- a/sc/source/ui/docshell/dataprovider.cxx
+++ b/sc/source/ui/docshell/dataprovider.cxx
@@ -11,8 +11,10 @@
 #include <stringutil.hxx>
 
 #if defined(_WIN32)
+#if !defined __ORCUS_STATIC_LIB // avoid -Werror,-Wunused-macros
 #define __ORCUS_STATIC_LIB
 #endif
+#endif
 #include <orcus/csv_parser.hpp>
 
 namespace sc {
commit 2e54c5a0b4af99d8c5037f1404a2f7095a9c5d11
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Fri Dec 16 15:24:51 2016 +0100

    -Werror,-Wstrict-prototypes (clang-cl)
    
    (sal/inc/rtllifecycle.h only hits on Windows as that is the only platform that happens to
    actually include it in a C compilation unit, sal/osl/w32/dllentry.c)
    
    Change-Id: I2878b52daf713ea45eaa2968cc5d2686b86abfe6

diff --git a/odk/source/unoapploader/win/unoapploader.c b/odk/source/unoapploader/win/unoapploader.c
index 9b2c1d3..e010aef 100644
--- a/odk/source/unoapploader/win/unoapploader.c
+++ b/odk/source/unoapploader/win/unoapploader.c
@@ -35,11 +35,11 @@
 
 #define MY_LENGTH(s) (sizeof (s) / sizeof *(s) - 1)
 
-char const* getPath();
+char const* getPath(void);
 char* createCommandLine( char* lpCmdLine );
 FILE* getErrorFile( int create );
 void writeError( const char* errstr );
-void closeErrorFile();
+void closeErrorFile(void);
 
 /*
  * The main function implements a loader for applications which use UNO.
diff --git a/sal/inc/rtllifecycle.h b/sal/inc/rtllifecycle.h
index 29a493b..82e38de 100644
--- a/sal/inc/rtllifecycle.h
+++ b/sal/inc/rtllifecycle.h
@@ -14,29 +14,29 @@
 extern "C" {
 #endif
 
-void rtl_arena_init();
+void rtl_arena_init(void);
 
-void rtl_arena_fini();
+void rtl_arena_fini(void);
 
-void ensureArenaSingleton();
+void ensureArenaSingleton(void);
 
-void rtl_cache_init();
+void rtl_cache_init(void);
 
-void rtl_cache_fini();
+void rtl_cache_fini(void);
 
-void ensureCacheSingleton();
+void ensureCacheSingleton(void);
 
-void rtl_memory_init();
+void rtl_memory_init(void);
 
-void rtl_memory_fini();
+void rtl_memory_fini(void);
 
-void ensureMemorySingleton();
+void ensureMemorySingleton(void);
 
-void rtl_locale_init();
+void rtl_locale_init(void);
 
-void rtl_locale_fini();
+void rtl_locale_fini(void);
 
-void ensureLocaleSingleton();
+void ensureLocaleSingleton(void);
 
 #if defined __cplusplus
 }


More information about the Libreoffice-commits mailing list