aboutsummaryrefslogtreecommitdiff
path: root/contrib/native/client/src/include
diff options
context:
space:
mode:
authoralzarei <azarei@ece.ubc.ca>2015-02-16 14:41:28 -0800
committerParth Chandra <pchandra@maprtech.com>2015-02-17 16:15:33 -0800
commitab4d799807bdcf6ecb74c6c0ffd655d6a1a965ad (patch)
tree0c0ce5c5b1d18fa6f47f5ebd812ab0e093a5c59c /contrib/native/client/src/include
parent36fc560f0eebd39cdb4509bcfd180230bb9f3c22 (diff)
DRILL-1219. C++ Client. Fix timeout for 32-bit windows platform
Diffstat (limited to 'contrib/native/client/src/include')
-rw-r--r--contrib/native/client/src/include/drill/common.hpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/contrib/native/client/src/include/drill/common.hpp b/contrib/native/client/src/include/drill/common.hpp
index 824d67062..e149ed11d 100644
--- a/contrib/native/client/src/include/drill/common.hpp
+++ b/contrib/native/client/src/include/drill/common.hpp
@@ -50,6 +50,14 @@
#define CODER_DEBUGGING
#endif
+// http://www.boost.org/doc/libs/1_54_0/doc/html/boost_asio/reference/basic_stream_socket/cancel/overload1.html
+// : "Calls to cancel() will always fail with boost::asio::error::operation_not_supported when run on Windows XP, Windows Server 2003, and earlier versions of Windows..."
+// As such, achieving cancel needs to be implemented differently;
+#if defined(_WIN32) && !defined(_WIN64)
+#define WIN32_SHUTDOWN_ON_TIMEOUT
+#endif // _WIN32 && !_WIN64
+
+
namespace Drill {
typedef std::vector<uint8_t> DataBuf;