From 24d421cf7eb30d9c19d3bf65ab152a3838d511cd Mon Sep 17 00:00:00 2001 From: "benjamin@smedbergs.us" Date: Fri, 29 Feb 2008 06:49:04 -0800 Subject: [PATCH] Bug 420217 - _InterlockedCompareExchange needs to be extern "C" when using a C++ compiler, r=brendan a1.9b4=beltzner --- js/src/jslock.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/js/src/jslock.c b/js/src/jslock.c index 6d4fc4cd40fd..50402b4fc533 100644 --- a/js/src/jslock.c +++ b/js/src/jslock.c @@ -86,8 +86,10 @@ js_UnlockGlobal(void *id) /* Exclude Alpha NT. */ #if defined(_WIN32) && defined(_M_IX86) #pragma warning( disable : 4035 ) +JS_BEGIN_EXTERN_C extern long __cdecl _InterlockedCompareExchange(long *volatile dest, long exchange, long comp); +JS_END_EXTERN_C #pragma intrinsic(_InterlockedCompareExchange) static JS_INLINE int