[x86/Linux] Fix prototype for GCThreadStub (#8397)
authorSaeHie Park <saehie.park@gmail.com>
Wed, 30 Nov 2016 14:21:04 +0000 (23:21 +0900)
committerJan Vorlicek <janvorli@microsoft.com>
Wed, 30 Nov 2016 14:21:04 +0000 (15:21 +0100)
Fix compile error for x86/Linux
- fix "cannot initialize a parameter of type 'LPTHREAD_START_ROUTINE'"
- add __stdcall GCThreadStub as it's Windows/Linux common code

src/vm/gcenv.os.cpp
tests/src/Common/Platform/platformdefines.h

index 896dce6..bfd9c4c 100644 (file)
@@ -639,7 +639,7 @@ struct GCThreadStubParam
 };
 
 // GC thread stub to convert GC thread function to an OS specific thread function
-static DWORD GCThreadStub(void* param)
+static DWORD __stdcall GCThreadStub(void* param)
 {
     WRAPPER_NO_CONTRACT;
 
index c196b0c..0961e86 100644 (file)
@@ -72,7 +72,7 @@ LPWSTR HackyConvertToWSTR(char* pszInput);
 
 typedef pthread_t THREAD_ID;
 typedef void* (*MacWorker)(void*);
-typedef DWORD (*LPTHREAD_START_ROUTINE)(void*);
+typedef DWORD __stdcall (*LPTHREAD_START_ROUTINE)(void*);
 #ifdef UNICODE
 typedef WCHAR TCHAR;
 #else // ANSI