From 051789fb4a61c92a9309a5fa101d0de8d036fe0e Mon Sep 17 00:00:00 2001 From: antoine Date: Sat, 10 May 2008 18:39:20 +0000 Subject: [PATCH] Remove useless call to getdtablesize(2) in fdopen(3) and its useless variable nofile. PR: 123109 Submitted by: Christoph Mallon Approved by: rwatson (mentor) MFC after: 1 month --- lib/libc/stdio/fdopen.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/lib/libc/stdio/fdopen.c b/lib/libc/stdio/fdopen.c index 072d3227cc05..26e2cd70bc1e 100644 --- a/lib/libc/stdio/fdopen.c +++ b/lib/libc/stdio/fdopen.c @@ -52,12 +52,8 @@ fdopen(fd, mode) const char *mode; { FILE *fp; - static int nofile; int flags, oflags, fdflags, tmp; - if (nofile == 0) - nofile = getdtablesize(); - /* * File descriptors are a full int, but _file is only a short. * If we get a valid file descriptor that is greater than