summaryrefslogtreecommitdiff
path: root/extensions
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2018-01-31 12:47:22 +0300
committerMike Kaganski <mike.kaganski@collabora.com>2018-02-01 10:42:07 +0100
commitdc4dae12637bf0e5ef5d05bec8cf2577cef75f42 (patch)
treea4a938bc7fa3bc7448cfb337b8f5b7ee1bb274d2 /extensions
parent98e9e033527d5f50df1fbf2918358c6f529d63ad (diff)
extensions: MSVC: pragma warning: make more specific, remove obsolete
Change-Id: I7bbb280810af51adc25595667f1c40aca0a8ae26 Reviewed-on: https://gerrit.libreoffice.org/48977 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'extensions')
-rw-r--r--extensions/source/activex/SOActiveX.cxx5
-rw-r--r--extensions/source/activex/SOActiveX.h5
-rw-r--r--extensions/source/activex/StdAfx2.h14
-rw-r--r--extensions/source/ole/oledll.cxx5
-rw-r--r--extensions/source/ole/wincrap.hxx7
-rw-r--r--extensions/source/ole/windata.hxx6
-rw-r--r--extensions/source/scanner/scanwin.cxx7
-rw-r--r--extensions/source/update/check/download.cxx12
-rw-r--r--extensions/source/update/check/onlinecheck.cxx4
-rw-r--r--extensions/source/update/check/updatecheck.cxx7
-rw-r--r--extensions/source/update/check/updatecheckconfig.cxx7
11 files changed, 5 insertions, 74 deletions
diff --git a/extensions/source/activex/SOActiveX.cxx b/extensions/source/activex/SOActiveX.cxx
index cda7fff13df4..50515047d937 100644
--- a/extensions/source/activex/SOActiveX.cxx
+++ b/extensions/source/activex/SOActiveX.cxx
@@ -19,9 +19,6 @@
// SOActiveX.cpp : Implementation of CSOActiveX
-#pragma warning (push,1)
-#pragma warning (disable:4265)
-
#include "StdAfx2.h"
#include "SOActiveX.h"
#include "SOComWindowPeer.h"
@@ -37,8 +34,6 @@
#pragma clang diagnostic pop
#endif
-#pragma warning (pop)
-
#define STAROFFICE_WINDOWCLASS L"SOParentWindow"
diff --git a/extensions/source/activex/SOActiveX.h b/extensions/source/activex/SOActiveX.h
index b850a53a2b01..d55820be163b 100644
--- a/extensions/source/activex/SOActiveX.h
+++ b/extensions/source/activex/SOActiveX.h
@@ -24,9 +24,6 @@
#include "resource.h"
-#pragma warning (push,1)
-#pragma warning (disable:4265)
-
#include <ExDispID.h>
#include <ExDisp.h>
#include <shlguid.h>
@@ -42,8 +39,6 @@
#pragma clang diagnostic pop
#endif
-#pragma warning (pop)
-
class SODispatchInterceptor;
enum SOVersion {
diff --git a/extensions/source/activex/StdAfx2.h b/extensions/source/activex/StdAfx2.h
index 2d121dab1df2..0c48a5e5fb5a 100644
--- a/extensions/source/activex/StdAfx2.h
+++ b/extensions/source/activex/StdAfx2.h
@@ -24,10 +24,6 @@
#ifndef INCLUDED_EXTENSIONS_SOURCE_ACTIVEX_STDAFX2_H
#define INCLUDED_EXTENSIONS_SOURCE_ACTIVEX_STDAFX2_H
-#ifdef _MSC_VER
-#pragma once
-#endif
-
#define STRICT
#ifndef _WIN32_WINNT
#define _WIN32_WINNT 0x0502
@@ -35,11 +31,9 @@
#define _ATL_APARTMENT_THREADED
#define _ATL_STATIC_REGISTRY
-#pragma warning (push,1)
-#pragma warning (disable:4548)
- // expression before comma has no effect; expected expression with side-effect
-#pragma warning (disable:4555)
- // expression has no effect; expected expression with side-effect
+#pragma warning (push)
+#pragma warning (disable:4189)
+ // local variable is initialized but not referenced - in atlctl.h
#if defined __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wall"
@@ -75,6 +69,6 @@ extern CComModule _Module;
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
-#endif // !defined(AFX_STDAFX_H__C1799EA0_62CC_44DE_A2DD_C9F0410FF7F1__INCLUDED)
+#endif // !defined(INCLUDED_EXTENSIONS_SOURCE_ACTIVEX_STDAFX2_H)
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/extensions/source/ole/oledll.cxx b/extensions/source/ole/oledll.cxx
index c7f91ee7d9a1..fb6b673a9dba 100644
--- a/extensions/source/ole/oledll.cxx
+++ b/extensions/source/ole/oledll.cxx
@@ -21,9 +21,6 @@
#define STRICT
#define _WIN32_DCOM
-#pragma warning (push,1)
-#pragma warning (disable:4548)
-
#if defined __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wall"
@@ -45,8 +42,6 @@ static CComModule _Module;
#pragma clang diagnostic pop
#endif
-#pragma warning (pop)
-
BEGIN_OBJECT_MAP(ObjectMap)
#if defined __clang__
#pragma clang diagnostic push
diff --git a/extensions/source/ole/wincrap.hxx b/extensions/source/ole/wincrap.hxx
index 485c8c0aef67..7bef1b12b7dd 100644
--- a/extensions/source/ole/wincrap.hxx
+++ b/extensions/source/ole/wincrap.hxx
@@ -29,11 +29,6 @@
//#define _ATL_DEBUG_INTERFACES
#endif
-#pragma warning (push,1)
-#pragma warning (disable:4917)
-#pragma warning (disable:4005)
-#pragma warning (disable:4548)
-
#include <dispex.h>
#include <prewin.h>
@@ -67,8 +62,6 @@ extern CComModule _Module;
#include <postwin.h>
-#pragma warning (pop)
-
#endif // INCLUDED_EXTENSIONS_SOURCE_OLE_WINCRAP_HXX
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/extensions/source/ole/windata.hxx b/extensions/source/ole/windata.hxx
index 69aa63398d18..76b493199ab5 100644
--- a/extensions/source/ole/windata.hxx
+++ b/extensions/source/ole/windata.hxx
@@ -19,10 +19,6 @@
#ifndef INCLUDED_EXTENSIONS_SOURCE_OLE_WINDATA_HXX
#define INCLUDED_EXTENSIONS_SOURCE_OLE_WINDATA_HXX
-#pragma warning (push,1)
-#pragma warning (disable:4668)
-#pragma warning (disable:4548)
-
#include <oleidl.h>
#if defined __clang__
@@ -43,8 +39,6 @@
#pragma clang diagnostic pop
#endif
-#pragma warning (pop)
-
#include <osl/diagnose.h>
namespace ole_adapter
diff --git a/extensions/source/scanner/scanwin.cxx b/extensions/source/scanner/scanwin.cxx
index 052eeebf9271..45f1c6a71ab8 100644
--- a/extensions/source/scanner/scanwin.cxx
+++ b/extensions/source/scanner/scanwin.cxx
@@ -40,14 +40,7 @@
#include <vcl/sysdata.hxx>
#include "scanner.hxx"
-#if defined _MSC_VER
-#pragma warning (push,1)
-#pragma warning (disable:4668)
-#endif
#include <twain/twain.h>
-#if defined _MSC_VER
-#pragma warning (pop)
-#endif
using namespace ::com::sun::star;
diff --git a/extensions/source/update/check/download.cxx b/extensions/source/update/check/download.cxx
index 922b44272744..3f137c4c1448 100644
--- a/extensions/source/update/check/download.cxx
+++ b/extensions/source/update/check/download.cxx
@@ -18,17 +18,7 @@
*/
-#if defined(_WIN32)
-# ifdef _MSC_VER
-# pragma warning(push, 1) /* disable warnings within system headers */
-# endif
-# include <curl/curl.h>
-# ifdef _MSC_VER
-# pragma warning(pop)
-# endif
-#else
-# include <curl/curl.h>
-#endif
+#include <curl/curl.h>
#include <osl/diagnose.h>
#include <com/sun/star/beans/PropertyValue.hpp>
diff --git a/extensions/source/update/check/onlinecheck.cxx b/extensions/source/update/check/onlinecheck.cxx
index 4b8ac299c367..759b71f04791 100644
--- a/extensions/source/update/check/onlinecheck.cxx
+++ b/extensions/source/update/check/onlinecheck.cxx
@@ -17,10 +17,6 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
-#ifdef _MSC_VER
-#pragma warning( disable: 4668 )
-#endif
-
#include <sal/types.h>
#include <sal/macros.h>
diff --git a/extensions/source/update/check/updatecheck.cxx b/extensions/source/update/check/updatecheck.cxx
index 4f4e30e48568..e09eee8f97ed 100644
--- a/extensions/source/update/check/updatecheck.cxx
+++ b/extensions/source/update/check/updatecheck.cxx
@@ -41,14 +41,7 @@
#include <sal/macros.h>
#ifdef _WIN32
-#ifdef _MSC_VER
-#pragma warning(push,1) // disable warnings within system headers
-//#pragma warning(disable: 4917)
-#endif
#include <objbase.h>
-#ifdef _MSC_VER
-#pragma warning(pop)
-#endif
#endif
#include "onlinecheck.hxx"
diff --git a/extensions/source/update/check/updatecheckconfig.cxx b/extensions/source/update/check/updatecheckconfig.cxx
index eb361bf9bdfa..973729216c2f 100644
--- a/extensions/source/update/check/updatecheckconfig.cxx
+++ b/extensions/source/update/check/updatecheckconfig.cxx
@@ -31,15 +31,8 @@
#include <o3tl/char16_t2wchar_t.hxx>
#ifdef _WIN32
-#ifdef _MSC_VER
-#pragma warning(push,1) // disable warnings within system headers
-#pragma warning(disable: 4917)
-#endif
#include <objbase.h>
#include <shlobj.h>
-#ifdef _MSC_VER
-#pragma warning(pop)
-#endif
#endif
namespace container = com::sun::star::container ;