Bug 19140 - Process creation stress leads to crashes
Summary: Process creation stress leads to crashes
Alias: None
Product: Runtime
Classification: Mono
Component: io-layer ()
Version: unspecified
Hardware: PC Mac OS
: --- normal
Target Milestone: ---
Assignee: Bugzilla
Depends on:
Reported: 2014-04-17 18:16 UTC by Rodrigo Kumpera
Modified: 2014-10-16 13:18 UTC (History)
3 users (show)

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

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:

Description Rodrigo Kumpera 2014-04-17 18:16:15 UTC

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Diagnostics;
using System.IO;
namespace Test
    class Program
        static void Main(string[] args)
			new Thread (() => {
				for (int i = 0; i < 1000 * 500; ++i) {
					var p = Process.Start ("test.exe");
					Thread.Sleep (1);
					p.WaitForExit ();
			}).Start ();
			for (int j = 0; j < 1000; ++j) {
	            for (int i = 0; i <  1000 * 50; ++i) {
					try {
						Process.GetProcessById (i);
					} catch (ArgumentException) {}
				Console.Write (".");
				if (j > 0 && (j % 50) == 0)
					Console.WriteLine ("");
Comment 1 Zoltan Varga 2014-10-16 13:18:58 UTC
Fixed in master by bf87077ac90946229f356cc2f6eded8d77189da3.