Quantcast
Channel: Common Language Runtime Internals and Architecture forum
Viewing all articles
Browse latest Browse all 1710

Access violation in CLR when trying to release RCW's

$
0
0

Hello,

I have spent two days scratching my head trying to understand the following call stack...Any input/thoughts would be highly appreciated. Thanks in advance!

In order to diagnose heap corruption in the process, I enabled "Page heap" for it and attached it with WinDBG. I have been hitting access violation with the following call stack when invoking/instantiating a dialog in the application (it happens every time but the first invoke)

Looks like CLR is trying to cleanup a non-existent RCW. Any ideas on how can i find what RCW its trying to cleanup so that i can investigate the code in that area further?

>

Current frame: clr!SafeReleasePreemp+0x231
ChildEBP RetAddr  Caller, Callee
055dfb70 71936f36 clr!CtxEntry::EnterContext+0x3bf, calling clr!_EH_epilog3
055dfb9c 71935c17 clr!RCW::ReleaseAllInterfaces+0x70, calling clr!SafeReleasePreemp
055dfbb4 71935cb0 clr!RCW::ReleaseAllInterfacesCallBack+0x60, calling clr!RCW::ReleaseAllInterfaces
055dfbf0 71935d0c clr!RCW::Cleanup+0x41, calling clr!RCW::ReleaseAllInterfacesCallBack
055dfc24 71935e84 clr!RCWCleanupList::ReleaseRCWListRaw+0xd, calling clr!RCW::Cleanup
055dfc2c 71935e61 clr!RCWCleanupList::ReleaseRCWListInCorrectCtx+0xd1, calling clr!RCWCleanupList::ReleaseRCWListRaw
055dfc40 71936da2 clr!RCWCleanupList::CleanupAllWrappers+0x155, calling clr!RCWCleanupList::ReleaseRCWListInCorrectCtx
055dfc58 718511c5 clr!ClrFlsIncrementValue+0x9, calling clr!ClrFlsGetBlock
055dfc94 719f1800 clr!SyncBlockCache::DeleteSyncBlock+0xaa, calling clr!_EH_epilog3
055dfc9c 719f1725 clr!SyncBlockCache::CleanupSyncBlocks+0xd0, calling clr!RCWCleanupList::CleanupAllWrappers
055dfcec 719f168c clr!Thread::DoExtraWorkForFinalizer+0x81, calling clr!SyncBlockCache::CleanupSyncBlocks
055dfd04 71928744 clr!WKS::GCHeap::FinalizerThreadWorker+0x22f, calling clr!Thread::DoExtraWorkForFinalizer
055dfd44 71889843 clr!REGUTIL::EnvGetString+0xfc, calling clr!__security_check_cookie
055dfd4c 718c7d8d clr!Thread::DoExtraWorkForFinalizer+0x1ca
055dfd64 718c7dfb clr!Thread::DoExtraWorkForFinalizer+0x256, calling clr!Thread::DoExtraWorkForFinalizer+0x163
055dfd98 7196b5f2 clr!ThreadStore::TransferStartedThread+0xfd, calling clr!_EH_epilog3
055dfdd4 718898fd clr!SHash<StringSHashTraits<_ConfigStringKeyValuePair,unsigned short,CaseSensitiveStringCompareHash<unsigned short> > >::Lookup+0x11, calling clr!SHash<StringSHashTraits<_ConfigStringKeyValuePair,unsigned short,CaseSensitiveStringCompareHash<unsigned short> > >::Lookup
055dfde0 7188998a clr!EEConfig::GetConfiguration_DontUse_+0x1b0, calling clr!SHash<StringSHashTraits<_ConfigStringKeyValuePair,unsigned short,CaseSensitiveStringCompareHash<unsigned short> > >::Lookup
055dfe0c 718c7ec8 clr!Thread::DoExtraWorkForFinalizer+0x618, calling clr!Thread::DoExtraWorkForFinalizer+0x1d4
055dfe68 719141c6 clr!WKS::GCHeap::FinalizerThreadStart+0x198, calling clr!Thread::DoExtraWorkForFinalizer+0x5bd
055dfe84 77a9e023 ntdll!RtlFreeHeap+0x105, calling ntdll!RtlpLowFragHeapFree
055dfee4 7196a0c1 clr!Thread::intermediateThreadProc+0x4d
055dff74 7196a0af clr!Thread::intermediateThreadProc+0x3b, calling clr!_alloca_probe_16
055dff88 775733aa kernel32!BaseThreadInitThunk+0xe
055dff94 77aa9ef2 ntdll!__RtlUserThreadStart+0x70
055dffd4 77aa9ec5 ntdll!_RtlUserThreadStart+0x1b, calling ntdll!__RtlUserThreadStart




Viewing all articles
Browse latest Browse all 1710

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>