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:
authorBen Maurer <benm@mono-cvs.ximian.com>2005-05-27 03:18:18 +0400
committerBen Maurer <benm@mono-cvs.ximian.com>2005-05-27 03:18:18 +0400
commitdd19011aa66c00977c4e18b959d8c317860cbb63 (patch)
tree1e1b1a8c4358d7a735565a408ede2ad998f93699 /mcs/class/System/System.IO/FileSystemWatcher.cs
parentf1ea3a510690b826a250a0a0849fe583b589485a (diff)
locking fixes
svn path=/trunk/mcs/; revision=45088
Diffstat (limited to 'mcs/class/System/System.IO/FileSystemWatcher.cs')
-rw-r--r--mcs/class/System/System.IO/FileSystemWatcher.cs3
1 files changed, 2 insertions, 1 deletions
diff --git a/mcs/class/System/System.IO/FileSystemWatcher.cs b/mcs/class/System/System.IO/FileSystemWatcher.cs
index e4018da1210..d3d421ccc21 100644
--- a/mcs/class/System/System.IO/FileSystemWatcher.cs
+++ b/mcs/class/System/System.IO/FileSystemWatcher.cs
@@ -57,6 +57,7 @@ namespace System.IO {
bool disposed;
string mangledFilter;
static IFileWatcher watcher;
+ static object lockobj = new object ();
#endregion // Fields
@@ -104,7 +105,7 @@ namespace System.IO {
void InitWatcher ()
{
- lock (typeof (FileSystemWatcher)) {
+ lock (lockobj) {
if (watcher != null)
return;