[Mono-bugs] [Bug 528830] appdomain-unload.exe unit test fails

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Fri Sep 11 21:17:03 EDT 2009


http://bugzilla.novell.com/show_bug.cgi?id=528830

User romain at blogreen.org added comment
http://bugzilla.novell.com/show_bug.cgi?id=528830#c8





--- Comment #8 from Romain Tartière <romain at blogreen.org>  2009-09-11 19:17:01 MDT ---
Created an attachment (id=317967)
 --> (http://bugzilla.novell.com/attachment.cgi?id=317967)
Fix missing curly braces.

After a few more hours trying to fix this, I saw that the code indentation was
weird, svn blame says:

-----8<---------------
 36953     zoltan     /* Wait for the thread */    
 36953     zoltan     while ((res = WaitForSingleObjectEx (thread_handle,
INFINITE, TRUE) == WAIT_IO_COMPLETION)) {
 36953     zoltan         if (mono_thread_has_appdomain_ref
(mono_thread_current (), domain) && (mono_thread_interruption_requested ()))
 36953     zoltan             /* The unload thread tries to abort us */
 36953     zoltan             /* The icall wrapper will execute the abort */
 63434     zoltan             CloseHandle (thread_handle);
 36953     zoltan             return;
 36953     zoltan     }
-----8<---------------

So basically the code has written at revision 36953 and a fix has been
committed as revision 63434:

------------------------------------------------------------------------
r63434 | zoltan | 2006-08-07 17:43:43 +0200 (Lun 07 aoû 2006) | 5 lignes

2006-08-07  Zoltan Varga  <vargaz at gmail.com>

    * appdomain.c (mono_domain_unload): Close the thread handle of the unload
thread.
    Hopefully fixes #78949.

------------------------------------------------------------------------


This patch add curly braces so that the change 63434 does not make the core
return each time the while loop is entered, so reverse the behaviour as of
revision 36953.


With this patch, I still have random deadlocks (new investigation needed) but
the code stop crashing!

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list