Feh / nocache

minimize caching effects
BSD 2-Clause "Simplified" License
554 stars 53 forks source link

Fix off by one issue with NOCACHE_MAX_FDS #43

Closed shadjiiski closed 4 years ago

shadjiiski commented 4 years ago

Since NOCACHE_MAX_FDS should be an artificial cap for RLIMIT_NOFILE, it should follow the same convention for its value - it should be one greater than the maximum file descriptor that would be handled by nocache. However, it currently is 2 greater than that file descriptor.

This commit resolves that. Also:

Fixes #42