nex3/rb-inotify — pull request #40 by rudolph9 (2014-10-03 20:04:35+00:00)
Title: Non-blocking check for stop in notifier and some semantic stuff accessing inotify.

The pull makes three important changes:

* Non-blocking check for the `@stop` flag.
* `IO#select` / `Native#poll` (depending on `ruby_support_io?`) are called in a loop with a 1 second timeout prior to making the blocking `IO#readpartial` / `Native#read` call. Upon timeout the `@stop` flag is checked. Should the flag be set the method returns nil otherwise the loop continues and another call to `IO#select` / `Native#poll` is made.
* `:name` was added to the `Native::Event` struct and used accordingly in the `Event` class.
* The size when reading the inotify file descriptor is now based on a call to `Native#fpathconf` which accesses the running systems `NAME_MAX` system variable rather than arbitrarily using `64 * Native::Event.size`.