[Catalyst-commits] r10022 - Catalyst-Devel/1.00/branches/improved-restarter/lib/Catalyst/Watcher

autarch at dev.catalyst.perl.org autarch at dev.catalyst.perl.org
Tue May 5 19:50:29 GMT 2009


Author: autarch
Date: 2009-05-05 19:50:28 +0000 (Tue, 05 May 2009)
New Revision: 10022

Modified:
   Catalyst-Devel/1.00/branches/improved-restarter/lib/Catalyst/Watcher/Inotify.pm
Log:
No need to cancel the watcher on a DELETE_SELF event, Inotify2 does that internally.


Modified: Catalyst-Devel/1.00/branches/improved-restarter/lib/Catalyst/Watcher/Inotify.pm
===================================================================
--- Catalyst-Devel/1.00/branches/improved-restarter/lib/Catalyst/Watcher/Inotify.pm	2009-05-05 19:49:55 UTC (rev 10021)
+++ Catalyst-Devel/1.00/branches/improved-restarter/lib/Catalyst/Watcher/Inotify.pm	2009-05-05 19:50:28 UTC (rev 10022)
@@ -60,13 +60,10 @@
                 $self->_add_directory( $event->fullname );
                 push @interesting, $event;
             }
-            elsif ( $event->IN_DELETE_SELF ) {
-                $event->w->cancel;
+            elsif ( $event->IN_DELETE_SELF
+                    || $event->fullname =~ /$regex/ ) {
                 push @interesting, $event;
             }
-            elsif ( $event->fullname =~ /$regex/ ) {
-                push @interesting, $event;
-            }
         }
 
         return @interesting if @interesting;




More information about the Catalyst-commits mailing list