Exemplo n.º 1
0
        /// <summary>
        /// Creates a local process object that will be able to debug specified program.
        /// </summary>
        /// <remarks>The created process object will be empty -- you still have to call
        /// CreateProcess method on it to start debugging
        /// </remarks>
        /// <param name="version">versin of CLR to use for the process</param>
        /// <returns>The Process that got created.</returns>
        public MDbgProcess CreateLocalProcess(string version)
        {
            // This is called on the Main thread so it's safe to flush 
            FreeStaleUnmanagedResources();

            CorDebug.CorDebugger debugger;
            if (version == null)
                debugger = DefaultLocalDebugger;
            else
            {
                debugger = new CorDebugger(version);
                lock (m_CleanupList)
                {
                    m_CleanupList.Add(debugger, false);
                }
            }

            var p = new MDbgProcess(m_engine, debugger);
            return p;
        }
 public ManagedCallback(CorDebugger outer)
 {
     m_outer = outer;
 }