From 622ce603227223ff15e23de6262803535ec4f246 Mon Sep 17 00:00:00 2001 From: Mukul Sabharwal Date: Mon, 29 Apr 2019 17:42:13 -0700 Subject: [PATCH] Fix GetObjectReferences API when caller doesn't zero the param (dotnet/coreclr#24299) Commit migrated from https://github.com/dotnet/coreclr/commit/00a853313ee2943ce2e97e4e9e7a114e0e7bc689 --- src/coreclr/src/vm/proftoeeinterfaceimpl.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/coreclr/src/vm/proftoeeinterfaceimpl.cpp b/src/coreclr/src/vm/proftoeeinterfaceimpl.cpp index 74985a77bb3..467ab292928 100644 --- a/src/coreclr/src/vm/proftoeeinterfaceimpl.cpp +++ b/src/coreclr/src/vm/proftoeeinterfaceimpl.cpp @@ -6836,6 +6836,7 @@ HRESULT ProfToEEInterfaceImpl::GetObjectReferences(ObjectID objectId, ULONG32 cN { if (cNumReferences == 0) { + *pcNumReferences = 0; GCHeapUtilities::GetGCHeap()->DiagWalkObject(pBO, &CountContainedObjectRef, (void*)pcNumReferences); } else -- GitLab