summaryrefslogtreecommitdiff
path: root/tests/src/Interop
diff options
context:
space:
mode:
authorPat Gavlin <pagavlin@microsoft.com>2016-10-13 12:35:48 -0700
committerPat Gavlin <pagavlin@microsoft.com>2016-10-13 12:35:48 -0700
commitd84d2e4921cea1895b5ecb750604ca29d86eec4b (patch)
tree6045bdbf5d23f7b5e93919d0576c8b059bca24d4 /tests/src/Interop
parent1e37d9f35f757d77345fb75929f0472e9bb54c30 (diff)
downloadcoreclr-d84d2e4921cea1895b5ecb750604ca29d86eec4b.tar.gz
coreclr-d84d2e4921cea1895b5ecb750604ca29d86eec4b.tar.bz2
coreclr-d84d2e4921cea1895b5ecb750604ca29d86eec4b.zip
Fix a calling convention in SimpleStructNative.
The managed code expects `GetFptr` to have the `stdcall` calling convention. Because of the mismatch, the JIT-generated code was not cleaning up the stack after P/Invoking to this function on x86, which was causing a failure during GC stress.
Diffstat (limited to 'tests/src/Interop')
-rw-r--r--tests/src/Interop/SimpleStruct/SimpleStructNative.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/src/Interop/SimpleStruct/SimpleStructNative.cpp b/tests/src/Interop/SimpleStruct/SimpleStructNative.cpp
index 5fe82146b8..c64b33c3e7 100644
--- a/tests/src/Interop/SimpleStruct/SimpleStructNative.cpp
+++ b/tests/src/Interop/SimpleStruct/SimpleStructNative.cpp
@@ -81,7 +81,7 @@ DLL_EXPORT ExplStruct* _cdecl CdeclSimpleExplStruct(ExplStruct p,BOOL *result)
}
extern "C"
-DLL_EXPORT voidPtr _cdecl GetFptr(int i)
+DLL_EXPORT voidPtr __stdcall GetFptr(int i)
{
switch(i)
{