Linux::Inotify2 is a very thin wrapper for the inotify system calls. The poll returns with zero events because inotify_rm_watch causes an event on the watch descriptor (but this event is discarded).
Perhaps a modification to loop logic can fix your problem:
$inotify->poll while !$done;
In reply to Re: Linux::Inotify2 remove single watch
by Anonymous Monk
in thread Linux::Inotify2 remove single watch
by agarrubio
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |