From: Andy Ayers Date: Fri, 1 Feb 2019 19:34:31 +0000 (-0800) Subject: Ensure method is active in PrepareMethod (dotnet/coreclr#22351) X-Git-Tag: submit/tizen/20210909.063632~11030^2~2626 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=33e8fb0e20182fda95183c07ecc0048d58499524;p=platform%2Fupstream%2Fdotnet%2Fruntime.git Ensure method is active in PrepareMethod (dotnet/coreclr#22351) Fixes an assert when first call to PrepareMethod for an assembly is an interop method. Commit migrated from https://github.com/dotnet/coreclr/commit/7a453d4b05d3514b5c5c3b22411e3d2d9f16c017 --- diff --git a/src/coreclr/src/vm/reflectioninvocation.cpp b/src/coreclr/src/vm/reflectioninvocation.cpp index 7f3ad70..a69f543 100644 --- a/src/coreclr/src/vm/reflectioninvocation.cpp +++ b/src/coreclr/src/vm/reflectioninvocation.cpp @@ -1944,6 +1944,8 @@ static void PrepareMethodHelper(MethodDesc * pMD) GCX_PREEMP(); + pMD->EnsureActive(); + if (pMD->IsPointingToPrestub()) pMD->DoPrestub(NULL);