diff options
| author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-07-17 21:33:05 +0000 |
|---|---|---|
| committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-07-17 21:33:05 +0000 |
| commit | be41ba3bedef74d484bb25ce263a9ca71a8e0855 (patch) | |
| tree | 31fd612aab2860bf3ff165052a2e75730e4eda04 /include/ruby/win32.h | |
| parent | c6c2add36307a84ce12d96aea2df8d7bb27941db (diff) | |
| download | ruby-be41ba3bedef74d484bb25ce263a9ca71a8e0855.tar.gz ruby-be41ba3bedef74d484bb25ce263a9ca71a8e0855.tar.xz ruby-be41ba3bedef74d484bb25ce263a9ca71a8e0855.zip | |
* include/ruby/win32.h: include winsock headers in extern "C++" for
C++ extension libraries.
* include/ruby/missing.h (vsnprintf): workaround for VC++.
[ruby-core:23096]
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@24179 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include/ruby/win32.h')
| -rw-r--r-- | include/ruby/win32.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/ruby/win32.h b/include/ruby/win32.h index a7d07083a..7c0da1f49 100644 --- a/include/ruby/win32.h +++ b/include/ruby/win32.h @@ -27,8 +27,14 @@ extern "C" { // #include <stdarg.h> conflict with varargs.h? #if !defined(WSAAPI) +#if defined(__cplusplus) && defined(_MSC_VER) +extern "C++" { /* template without extern "C++" */ +#endif #include <winsock2.h> #include <ws2tcpip.h> +#if defined(__cplusplus) && defined(_MSC_VER) +} +#endif #endif #define NT 1 /* deprecated */ |
