aboutsummaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2015-09-25 16:23:15 -0700
committerGravatar Craig Tiller <ctiller@google.com>2015-09-25 16:23:15 -0700
commit0a775b38c754d8d756838d1c05d6564cc8ba928e (patch)
tree8abe62fd9476544fa513c090c362f423e2193f56 /include
parent9d17f09ebe294e1d727c194f45da0576b0b4b1dc (diff)
parentb70e3be0409225b0e389379cc62d740694b888ac (diff)
Merge pull request #2920 from nicolasnoble/winnt-check
Better handling of _WIN32_WINNT.
Diffstat (limited to 'include')
-rw-r--r--include/grpc/support/port_platform.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/include/grpc/support/port_platform.h b/include/grpc/support/port_platform.h
index 93291a174d..e5d45590ae 100644
--- a/include/grpc/support/port_platform.h
+++ b/include/grpc/support/port_platform.h
@@ -46,10 +46,11 @@
#define NOMINMAX
#endif /* NOMINMAX */
-#if defined(_WIN32_WINNT)
-#if _WIN32_WINNT < 0x0600
-#undef _WIN32_WINNT
-#define _WIN32_WINNT 0x0600
+#ifndef _WIN32_WINNT
+#error "Please compile grpc with _WIN32_WINNT of at least 0x600 (aka Windows Vista)"
+#else /* !defined(_WIN32_WINNT) */
+#if (_WIN32_WINNT < 0x0600)
+#error "Please compile grpc with _WIN32_WINNT of at least 0x600 (aka Windows Vista)"
#endif /* _WIN32_WINNT < 0x0600 */
#endif /* defined(_WIN32_WINNT) */