Lately one of our customers is facing irreproducable access violations with this call stack:
> ntdll.dll!TppCleanupGroupMemberDestroy() Unknown
ntdll.dll!TppAlpcpFree() Unknown
ntdll.dll!TpReleaseAlpcCompletion() Unknown
rpcrt4.dll!RPC_THREAD_POOL_ALPC::`scalar deleting destructor'(unsigned int) Unknown
rpcrt4.dll!LRPC_CASSOCIATION::~LRPC_CASSOCIATION() Unknown
rpcrt4.dll!LRPC_CASSOCIATION::`vector deleting destructor'(unsigned int) Unknown
rpcrt4.dll!LRPC_CASSOCIATION::RemoveAssociationDictionaryReference(void) Unknown
rpcrt4.dll!LRPC_CASSOCIATION::LrpcDeleteLingeringAssociations(void) Unknown
rpcrt4.dll!PerformGarbageCollection() Unknown
ntdll.dll!TppTimerpExecuteCallback() Unknown
ntdll.dll!TppWorkerThread() Unknown
kernel32.dll!BaseThreadInitThunk() Unknown
ntdll.dll!RtlUserThreadStart() Unknown
Error message is:
> Unhandled exception at 0x00007FFEF183E7D3 (ntdll.dll) in NGen1.dmp: 0xC0000005: Access violation reading location 0x0000000000000000.
The application core is written in c++ with Visual Studio 2013. The application core has a COM interface and a c++/cli interface to call components and to be called by components. The components are written in c#, some in vb.net.
ntdll.dll is:
> ntdll.dll C:\Windows\System32\ntdll.dll 10.0.17763.1192 (WinBuild.160101.0800) 17.12.2016 10:22
We tried to use Marshal.FinalReleaseComObject to release the com objects created in the application core and handed out to the components as soon as possible, but it didn't seem to have any positive effect.