コード例 #1
0
ファイル: rsappdomain.cpp プロジェクト: Afshintm/coreclr
// Neutered by process. Once we're neutered, we lose our backpointer to the CordbProcess object, and
// thus can't do things like call GetProcess() or Continue().
void CordbAppDomain::Neuter()
{
    // This check prevents us from calling this twice and underflowing the internal ref count!
    if (IsNeutered())
    {
        return;
    }
    _ASSERTE(GetProcess()->ThreadHoldsProcessLock());

    //
    // Disconnect any active breakpoints
    //
    {
        CordbBreakpoint* entry;
        HASHFIND find;

        for (entry =  m_breakpoints.FindFirst(&find);
             entry != NULL;
             entry =  m_breakpoints.FindNext(&find))
        {
            entry->Disconnect();
        }
    }

    // Mark as neutered so that our children can tell the appdomain has now
    // exited.
    CordbBase::Neuter();

    //
    // Purge neuter lists.
    //
    m_TypeNeuterList.NeuterAndClear(GetProcess());
    m_SweepableNeuterList.NeuterAndClear(GetProcess());


    m_assemblies.NeuterAndClear(GetProcess()->GetProcessLock());
    m_modules.NeuterAndClear(GetProcess()->GetProcessLock());
    m_sharedtypes.NeuterAndClear(GetProcess()->GetProcessLock());
    m_breakpoints.NeuterAndClear(GetProcess()->GetProcessLock());

}
コード例 #2
0
ファイル: rsclass.cpp プロジェクト: Hasithaerathna/coreclr
//-----------------------------------------------------------------------------
//  Destructor for CordbClass
//-----------------------------------------------------------------------------
CordbClass::~CordbClass()
{
    // We should have been explicitly neutered before our internal ref went to 0.
    _ASSERTE(IsNeutered());
}
コード例 #3
0
ファイル: rsappdomain.cpp プロジェクト: Afshintm/coreclr
CordbAppDomain::~CordbAppDomain()
{

    // We expect to be Neutered before being released. Neutering will release our process ref
    _ASSERTE(IsNeutered());
}
コード例 #4
0
//-----------------------------------------------------------------------------
// Destructor for CordbMDA object. Not much to do here since neutering should
// have taken care of it all.
//-----------------------------------------------------------------------------
CordbMDA::~CordbMDA()
{
    // Strings protected w/ holders that will automatically free them.
    _ASSERTE(IsNeutered());
}