diff options
author | Aditya Mandaleeka <adityam@microsoft.com> | 2017-03-23 16:23:05 -0700 |
---|---|---|
committer | Aditya Mandaleeka <adityam@microsoft.com> | 2017-03-29 12:05:39 -0700 |
commit | 8d02c0786825a27d67fb2af150f751dbda360bef (patch) | |
tree | c702d97c98dbf10da04aa28e89f6a642898e261e /src/gc/sample/GCSample.cpp | |
parent | 066793782f1100b55cf092f50fa15d6901d6be75 (diff) | |
download | coreclr-8d02c0786825a27d67fb2af150f751dbda360bef.tar.gz coreclr-8d02c0786825a27d67fb2af150f751dbda360bef.tar.bz2 coreclr-8d02c0786825a27d67fb2af150f751dbda360bef.zip |
Create a GCHandleTable interface with Init/Shutdown.
Diffstat (limited to 'src/gc/sample/GCSample.cpp')
-rw-r--r-- | src/gc/sample/GCSample.cpp | 15 |
1 files changed, 8 insertions, 7 deletions
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 @@ -126,17 +126,12 @@ int __cdecl main(int argc, char* argv[]) 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; } @@ -145,6 +140,12 @@ int __cdecl main(int argc, char* argv[]) return -1; // + // Initialize handle table + // + if (!pGCHandleTable->Initialize()) + return -1; + + // // Initialize current thread // ThreadStore::AttachCurrentThread(); |