diff options
author | Jisi Liu <jisi.liu@gmail.com> | 2017-08-11 12:08:00 -0700 |
---|---|---|
committer | Jisi Liu <jisi.liu@gmail.com> | 2017-08-11 12:08:00 -0700 |
commit | 564f02c91ec0e983806762de4b842a762e21bb47 (patch) | |
tree | 52a4a64303c8426f487f08624e5059b977b078cc /src/google/protobuf/testing | |
parent | 7afa796bb914c911cc3d40aeeba1ce63b2f83f99 (diff) |
Make win32_io only for MSVC
This excludes cygwin and mingw from using the self implemented
functions.
Diffstat (limited to 'src/google/protobuf/testing')
-rw-r--r-- | src/google/protobuf/testing/file.cc | 3 | ||||
-rw-r--r-- | src/google/protobuf/testing/googletest.cc | 2 |
2 files changed, 4 insertions, 1 deletions
diff --git a/src/google/protobuf/testing/file.cc b/src/google/protobuf/testing/file.cc index a1850e44..f32222b7 100644 --- a/src/google/protobuf/testing/file.cc +++ b/src/google/protobuf/testing/file.cc @@ -55,6 +55,9 @@ namespace protobuf { #define lstat stat // DO NOT include <io.h>, instead create functions in io_win32.{h,cc} and import // them like we do below. +#endif + +#ifdef _MSC_VER using google::protobuf::internal::win32::access; using google::protobuf::internal::win32::chdir; using google::protobuf::internal::win32::fopen; diff --git a/src/google/protobuf/testing/googletest.cc b/src/google/protobuf/testing/googletest.cc index c6fb00d4..33a75ed6 100644 --- a/src/google/protobuf/testing/googletest.cc +++ b/src/google/protobuf/testing/googletest.cc @@ -52,7 +52,7 @@ namespace google { namespace protobuf { -#ifdef _WIN32 +#ifdef _MSC_VER // DO NOT include <io.h>, instead create functions in io_win32.{h,cc} and import // them like we do below. using google::protobuf::internal::win32::close; |