From 8d02c0786825a27d67fb2af150f751dbda360bef Mon Sep 17 00:00:00 2001 From: Aditya Mandaleeka Date: Thu, 23 Mar 2017 16:23:05 -0700 Subject: Create a GCHandleTable interface with Init/Shutdown. --- src/gc/sample/GCSample.cpp | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'src/gc/sample/GCSample.cpp') diff --git a/src/gc/sample/GCSample.cpp b/src/gc/sample/GCSample.cpp index 2c32048bbb..5d5371c76e 100644 --- a/src/gc/sample/GCSample.cpp +++ b/src/gc/sample/GCSample.cpp @@ -125,18 +125,13 @@ int __cdecl main(int argc, char* argv[]) freeObjectMT.InitializeFreeObject(); g_pFreeObjectMethodTable = &freeObjectMT; - // - // Initialize handle table - // - if (!Ref_Initialize()) - return -1; - // // Initialize GC heap // GcDacVars dacVars; IGCHeap *pGCHeap; - if (!InitializeGarbageCollector(nullptr, &pGCHeap, &dacVars)) + IGCHandleTable *pGCHandleTable; + if (!InitializeGarbageCollector(nullptr, &pGCHeap, &pGCHandleTable, &dacVars)) { return -1; } @@ -144,6 +139,12 @@ int __cdecl main(int argc, char* argv[]) if (FAILED(pGCHeap->Initialize())) return -1; + // + // Initialize handle table + // + if (!pGCHandleTable->Initialize()) + return -1; + // // Initialize current thread // -- cgit v1.2.3