Skip to content

Commit

Permalink
Backport of r135460
Browse files Browse the repository at this point in the history
svn path=/branches/mono-2-4/mcs/; revision=135462
  • Loading branch information
grendello committed Jun 4, 2009
1 parent 181c888 commit cde24e9
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 5 deletions.
5 changes: 5 additions & 0 deletions mcs/class/System.Web/System.Web/ChangeLog
@@ -1,3 +1,8 @@
2009-06-04 Marek Habersack <mhabersack@novell.com>

* HttpApplicationFactory.cs: OnFileChanged ignores the directory
part of the file triggering the event. Fixes bug #509998

2009-06-03 Marek Habersack <mhabersack@novell.com>

* VirtualPathUtility.cs: IsValidVirtualPath now checks the value
Expand Down
8 changes: 4 additions & 4 deletions mcs/class/System.Web/System.Web/HttpApplicationFactory.cs
Expand Up @@ -717,10 +717,10 @@ static void OnFileRenamed(object sender, RenamedEventArgs args)
static void OnFileChanged(object sender, FileSystemEventArgs args)
{
string name = args.Name;

if (StrUtils.EndsWith (name, "onfig", true) && String.Compare (name, "web.config", true) != 0)
return;
if (StrUtils.EndsWith (name, "lobal.asax", true) && String.Compare (name, "global.asax", true) != 0)
if (StrUtils.EndsWith (name, "onfig", true)) {
if (String.Compare (Path.GetFileName (name), "web.config", true) != 0)
return;
} else if (StrUtils.EndsWith (name, "lobal.asax", true) && String.Compare (name, "global.asax", true) != 0)
return;

// {Inotify,FAM}Watcher will notify about events for a directory regardless
Expand Down
6 changes: 6 additions & 0 deletions mcs/class/System/System.IO/ChangeLog
@@ -1,3 +1,9 @@
2009-06-04 Marek Habersack <mhabersack@novell.com>

* InotifyWatcher.cs: filter pattern should be matched on file name
alone, not on the relative path of the file triggering the
event. Fixes bug #509998

2009-03-11 Gonzalo Paniagua Javier <gonzalo@novell.com>

* InotifyWatcher.cs: don't send events when a directory is created
Expand Down
2 changes: 1 addition & 1 deletion mcs/class/System/System.IO/InotifyWatcher.cs
Expand Up @@ -547,7 +547,7 @@ void ProcessEvents (byte [] buffer, int length)
}
}

if (filename != data.Directory && !fsw.Pattern.IsMatch (filename)) {
if (filename != data.Directory && !fsw.Pattern.IsMatch (Path.GetFileName (filename))) {
continue;
}

Expand Down

0 comments on commit cde24e9

Please sign in to comment.