Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiguel de Icaza <miguel@gnome.org>2009-04-20 07:57:44 +0400
committerMiguel de Icaza <miguel@gnome.org>2009-04-20 07:57:44 +0400
commit401337e29703e6ec6c374e2a0eaa9cfc568d3db6 (patch)
treeaf7507a9fd2b6a26bdfa4717bc64442b82748c14 /mcs/class/System/System.Diagnostics/Process.cs
parentf549ba4f016fedafc563c15aa1eb282bf09b2426 (diff)
2009-04-19 Miguel de Icaza <miguel@novell.com>
* Process.cs: Do not crash if GetProcesses_internal returns null This happens on operating systems where we have not implemented svn path=/trunk/mcs/; revision=132110
Diffstat (limited to 'mcs/class/System/System.Diagnostics/Process.cs')
-rw-r--r--mcs/class/System/System.Diagnostics/Process.cs3
1 files changed, 3 insertions, 0 deletions
diff --git a/mcs/class/System/System.Diagnostics/Process.cs b/mcs/class/System/System.Diagnostics/Process.cs
index 0f511250be2..5db07962592 100644
--- a/mcs/class/System/System.Diagnostics/Process.cs
+++ b/mcs/class/System/System.Diagnostics/Process.cs
@@ -857,6 +857,9 @@ namespace System.Diagnostics {
{
int [] pids = GetProcesses_internal ();
ArrayList proclist = new ArrayList ();
+
+ if (pids == null)
+ return new Process [0];
for (int i = 0; i < pids.Length; i++) {
try {