Created
October 23, 2009 08:22
-
-
Save kazeburo/216746 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/Filesys/Notify/Simple.pm b/lib/Filesys/Notify/Simple.pm | |
index 70df639..44f4828 100644 | |
--- a/lib/Filesys/Notify/Simple.pm | |
+++ b/lib/Filesys/Notify/Simple.pm | |
@@ -47,7 +47,8 @@ sub wait_inotify2 { | |
Linux::Inotify2->import; | |
my $inotify = Linux::Inotify2->new; | |
- for my $path (@path) { | |
+ my $fs = _full_scan(@path); | |
+ for my $path (keys %$fs) { | |
$inotify->watch($path, &IN_MODIFY|&IN_CREATE|&IN_DELETE|&IN_DELETE_SELF|&IN_MOVE_SELF); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment