Fix undefined OPEN_MAX error
Not all systems define POSIX.1 value OPEN_MAX. In this case just close all descriptors up to some arbitrary limit - say 256 [1].
[1] Advanced Programming in the UNIX Environment, Richard Stevens, p. 52.
Authored by: Jörg Krause 2015-07-16
Parent(s): [f2e083]
Child(ren): [260b72]