Przeglądaj źródła

avoid c++ macro redifitnion on windows

woegster 6 lat temu
rodzic
commit
bba24bcb6b
1 zmienionych plików z 2 dodań i 0 usunięć
  1. 2 0
      src/google/protobuf/stubs/common.cc

+ 2 - 0
src/google/protobuf/stubs/common.cc

@@ -39,7 +39,9 @@
 #include <vector>
 
 #ifdef _WIN32
+#ifndef WIN32_LEAN_AND_MEAN
 #define WIN32_LEAN_AND_MEAN  // We only need minimal includes
+#endif
 #include <windows.h>
 #define snprintf _snprintf    // see comment in strutil.cc
 #elif defined(HAVE_PTHREAD)