c++ - application get hung while freelibrary -
i got crashdump generated drwtsn32 on site, show application blocked while invoking system api freelibrary. here's class stack:
childebp retaddr args child 06f0fc14 7c827d29 7c83d266 00000718 00000000 ntdll!kifastsystemcallret (fpo: [0,0,0]) 06f0fc18 7c83d266 00000718 00000000 00000000 ntdll!zwwaitforsingleobject+0xc (fpo: [3,0,0]) 06f0fc54 7c83d2b1 00000718 00000004 00000000 ntdll!rtlpwaitoncriticalsection+0x1a3 (fpo: [2,7,4]) 06f0fc74 7c839874 7c8897a0 00000000 00000000 ntdll!rtlentercriticalsection+0xa8 (fpo: [1,1,0]) 06f0fd7c 77e6b1bb 014e0000 00000000 02a67430 ntdll!ldrunloaddll+0x35 (fpo: [seh]) 06f0fd90 005e8cdd 014e0000 02a4bc88 06f0fdbc kernel32!freelibrary+0x41 (fpo: [1,0,0]) ....
i noticed line ntdll!rtlentercriticalsection+0xa8 (fpo: [1,1,0]), , think should critical_section relative. used dt command in windbg show critical_section information it
0:037> dt 7c8897a0 rtl_critical_section siteadminsvc!rtl_critical_section +0x000 debuginfo : 0x7c8897c0 _rtl_critical_section_debug +0x004 lockcount : -18 +0x008 recursioncount : 1 +0x00c owningthread : 0x00002098 +0x010 locksemaphore : 0x00000718 +0x014 spincount : 0
the line +0x00c owningthread : 0x00002098 show critical_section held thread 0x2098, it's strange can't find such thread in thread list.
is there other method find out why freelibrary blocked ?
ps: there story hung. if debug application using remote debugger, no hung met. if start application on server machine. much
i'm assuming calling freelibrary @ disallowed moment in time (like dllmain)
why not call freelibrary entry point function?
msdn: loaderlock mda
> however, apparently cannot call freelibrary dllmain process_detach event
Comments
Post a Comment