Bug 4384 - mono 2.11 for windows: Shutting down finalizer thread timed out.
Summary: mono 2.11 for windows: Shutting down finalizer thread timed out.
Status: RESOLVED FIXED
Alias: None
Product: Runtime
Classification: Mono
Component: General ()
Version: unspecified
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: Rodrigo Kumpera
URL:
Depends on:
Blocks:
 
Reported: 2012-04-10 17:23 UTC by Vincent Povirk
Modified: 2012-05-09 17:03 UTC (History)
3 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
C# source code of the program I'm using to test (117 bytes, text/x-csharp)
2012-04-10 17:23 UTC, Vincent Povirk
Details
proposed fix (2.34 KB, patch)
2012-05-09 12:20 UTC, Vincent Povirk
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Vincent Povirk 2012-04-10 17:23:43 UTC
Created attachment 1651 [details]
C# source code of the program I'm using to test

About 1 in 6 times when I run a "hello world" program using Mono 2.11 on Windows, I get a message that says "Shutting down finalizer thread timed out." before the program quits.
Comment 1 Vincent Povirk 2012-05-09 12:20:51 UTC
Created attachment 1837 [details]
proposed fix

This patch should fix the problem, and in my testing it seems to work.

We have to do SuspendThread from mono_threads_CreateThread to be sure the thread is suspended before that function returns, and we have to add some other synchronization to make sure the thread won't call the start routine before we can suspend it.
Comment 2 Rodrigo Kumpera 2012-05-09 16:25:37 UTC
Patch looks good. can you make a pull request out of it?

Thanks.
Comment 3 Rodrigo Kumpera 2012-05-09 17:03:52 UTC
Commit merged, thanks.