]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Windows: better wrap C++-specific code in compat layer
authorAmos Jeffries <squid3@treenet.co.nz>
Thu, 11 Oct 2012 07:19:02 +0000 (01:19 -0600)
committerAmos Jeffries <squid3@treenet.co.nz>
Thu, 11 Oct 2012 07:19:02 +0000 (01:19 -0600)
compat/os/mswindows.h
include/squid.h

index 5644a2894540d742cc9eeb8e7052dca82b6bfdbb..9f400e9b822b0d6d488f886f39656245fe6520ab 100644 (file)
@@ -388,7 +388,7 @@ SQUIDCEXTERN int _free_osfhnd(int);
 
 SQUIDCEXTERN THREADLOCAL int ws32_result;
 
-#ifdef __cplusplus
+#if defined(__cplusplus)
 
 inline int
 close(int fd)
index b844bddf18537eb3b055bc8e2d449558e7934488..2e9c7d52f6128a7d005cc6cecfde471d54825914 100644 (file)
 /* temp hack: needs to be pre-defined for now. */
 #define SQUID_MAXPATHLEN 256
 
-// TODO: determine if this is required. OR if compat/os/mswin.h works
-#if _SQUID_WINDOWS_
+// TODO: determine if this is required. OR if compat/os/mswindows.h works
+#if _SQUID_WINDOWS_ && defined(__cplusplus)
 /** \cond AUTODOCS-IGNORE */
 using namespace Squid;
 /** \endcond */