From b1d703d54a1cd79eb3a805548ee375af2236a614 Mon Sep 17 00:00:00 2001 From: Tom McDonald Date: Thu, 9 Apr 2026 14:51:14 -0400 Subject: [PATCH] Fix GetNativeCodeInfo to use async variant for thunk MethodDescs PR 125900 replaced GetAsyncOtherVariantNoCreate with GetOrdinaryVariantNoCreate, but for a thunk the correct target is the async variant. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- src/coreclr/debug/daccess/dacdbiimpl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/coreclr/debug/daccess/dacdbiimpl.cpp b/src/coreclr/debug/daccess/dacdbiimpl.cpp index 1891248bb85c10..067751ad253a18 100644 --- a/src/coreclr/debug/daccess/dacdbiimpl.cpp +++ b/src/coreclr/debug/daccess/dacdbiimpl.cpp @@ -1352,7 +1352,7 @@ HRESULT STDMETHODCALLTYPE DacDbiInterfaceImpl::GetNativeCodeInfo(VMPTR_DomainAss MethodDesc* pMethodDesc = FindLoadedMethodRefOrDef(pModule, functionToken); if (pMethodDesc != NULL && pMethodDesc->IsAsyncThunkMethod()) { - MethodDesc* pAsyncVariant = pMethodDesc->GetOrdinaryVariantNoCreate(); + MethodDesc* pAsyncVariant = pMethodDesc->GetAsyncVariantNoCreate(); if (pAsyncVariant != NULL) { pMethodDesc = pAsyncVariant;