Browse Source

[master] Merged trac3828 (IN macros guard)

Francis Dupont 10 years ago
parent
commit
ce0d400104
2 changed files with 16 additions and 2 deletions
  1. 8 1
      src/lib/dns/rrclass-placeholder.h
  2. 8 1
      src/lib/dns/rrclass.h

+ 8 - 1
src/lib/dns/rrclass-placeholder.h

@@ -1,4 +1,4 @@
-// Copyright (C) 2010  Internet Systems Consortium, Inc. ("ISC")
+// Copyright (C) 2010, 2015  Internet Systems Consortium, Inc. ("ISC")
 //
 // Permission to use, copy, modify, and/or distribute this software for any
 // purpose with or without fee is hereby granted, provided that the above
@@ -24,6 +24,13 @@
 
 #include <boost/optional.hpp>
 
+// Undefine the macro IN which is defined in some operating systems
+// but conflicts the IN RR class.
+
+#ifdef IN
+#undef IN
+#endif
+
 namespace isc {
 namespace util {
 class InputBuffer;

+ 8 - 1
src/lib/dns/rrclass.h

@@ -5,7 +5,7 @@
 ///////////////
 ///////////////
 
-// Copyright (C) 2010  Internet Systems Consortium, Inc. ("ISC")
+// Copyright (C) 2010, 2015  Internet Systems Consortium, Inc. ("ISC")
 //
 // Permission to use, copy, modify, and/or distribute this software for any
 // purpose with or without fee is hereby granted, provided that the above
@@ -31,6 +31,13 @@
 
 #include <boost/optional.hpp>
 
+// Undefine the macro IN which is defined in some operating systems
+// but conflicts the IN RR class.
+
+#ifdef IN
+#undef IN
+#endif
+
 namespace isc {
 namespace util {
 class InputBuffer;