diff options
Diffstat (limited to 'io.c')
-rw-r--r-- | io.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -201,7 +201,7 @@ rb_update_max_fd(int fd) rb_atomic_t max_fd = max_file_descriptor; int err; - if (afd <= max_fd) + if (fd < 0 || afd <= max_fd) return; #if defined(HAVE_FCNTL) && defined(F_GETFL) |