You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by ts...@apache.org on 2020/08/07 15:13:44 UTC

[logging-log4cxx] 01/03: Less warnings in Visual Studio 2015.

This is an automated email from the ASF dual-hosted git repository.

tschoening pushed a commit to branch logcxx_455_quiet_mode
in repository https://gitbox.apache.org/repos/asf/logging-log4cxx.git

commit 7463aa4687fb9d625d507166021dd0e294bf9d24
Author: Thorsten Schöning <ts...@am-soft.de>
AuthorDate: Fri Aug 7 16:16:10 2020 +0200

    Less warnings in Visual Studio 2015.
    
    https://issues.apache.org/jira/projects/LOGCXX/issues/LOGCXX-490
---
 src/changes/changes.xml           | 1 +
 src/main/include/log4cxx/logger.h | 4 ++++
 2 files changed, 5 insertions(+)

diff --git a/src/changes/changes.xml b/src/changes/changes.xml
index 21d0691..314c671 100644
--- a/src/changes/changes.xml
+++ b/src/changes/changes.xml
@@ -33,6 +33,7 @@
 			<action issue="LOGCXX-500" type="update">Logging in Timing-Critical Applications</action>
 			<action issue="LOGCXX-494" type="fix">Provide a windows build environment for the project by replacing the ant build with a CMake build</action>
 			<action issue="LOGCXX-493" type="fix">Wrong usage of milli- vs. micro- and non- vs. milliseconds in some docs.</action>
+			<action issue="LOGCXX-490" type="fix">conditional expression is constant</action>
 			<action issue="LOGCXX-488" type="fix">Space after log level hides messages</action>
 			<action issue="LOGCXX-484" type="fix">Spelling error s/excute/execute</action>
 			<action issue="LOGCXX-483" type="update">Not able to see hebrew values when logging in log4cxx</action>
diff --git a/src/main/include/log4cxx/logger.h b/src/main/include/log4cxx/logger.h
index 2db5d9e..07a9047 100644
--- a/src/main/include/log4cxx/logger.h
+++ b/src/main/include/log4cxx/logger.h
@@ -18,6 +18,10 @@
 #ifndef _LOG4CXX_LOGGER_H
 #define _LOG4CXX_LOGGER_H
 
+#if defined(_MSC_VER) && (_MSC_VER < 1900)
+	#pragma warning ( push )
+	#pragma warning ( disable: 4127 )
+#endif
 #if defined(_MSC_VER)
 	#pragma warning ( push )
 	#pragma warning ( disable: 4231 4251 4275 4786 )