[ros-dev] KeRundownThread question

Alex Ionescu ionucu at videotron.ca
Sat Mar 26 12:30:38 CET 2005


Hartmut Birr wrote:

>Hi,
>
>in KeRundownThread  is an ASSERT statement. What is the reason for that?
>ApcDisable is never changed. It is always 1 for mutex objects and always
>0 for mutant objects. If a mutant object is on the list, ros does crash.
>
>- Hartmut
>
>Index: ntoskrnl/ke/kthread.c
>===================================================================
>--- ntoskrnl/ke/kthread.c       (revision 14297)
>+++ ntoskrnl/ke/kthread.c       (working copy)
>@@ -360,7 +360,7 @@
>
>         /* Get the Mutant */
>         Mutant = CONTAINING_RECORD(CurrentEntry, KMUTANT, MutantListEntry);
>-        ASSERT(Mutant->ApcDisable);
>+//        ASSERT(Mutant->ApcDisable);
>
>
>  
>
It should actually be a bugcheck with THREAD_TERMINATE_HELD_MUTEX, but I 
only discovered this weird Bugcode much later after coding this. See 
some information here:

http://groups-beta.google.com/group/comp.os.ms-windows.nt.misc/browse_frm/thread/50aed4e7d60e894a/9d03b8eec3fd990b?q=THREAD_TERMINATE_HELD_MUTEX&rnum=1#9d03b8eec3fd990b

here:

/
// MessageId: *THREAD_TERMINATE_HELD_MUTEX*
//
// MessageText:
//
//  A kernel thread terminated while holding a mutex
//

Best regards,
Alex Ionescu



More information about the Ros-dev mailing list