* syscalls.cc (setdtablesize): Call with amount to increment not total amount.

Return success or failure error code.
This commit is contained in:
Christopher Faylor 2001-01-18 04:26:04 +00:00
parent d0319c3b5b
commit 4e2a97b2ac
2 changed files with 10 additions and 3 deletions

View File

@ -1,3 +1,8 @@
Wed Jan 17 23:23:12 2001 Christopher Faylor <cgf@cygnus.com>
* syscalls.cc (setdtablesize): Call with amount to increment not total
amount. Return success or failure error code.
Wed Jan 17 09:47:13 2001 Christopher Faylor <cgf@cygnus.com>
* autoload.cc (LoadDLLinitfunc): Remove debugging statement.

View File

@ -1345,11 +1345,13 @@ system (const char *cmdstring)
return res;
}
extern "C" void
extern "C" int
setdtablesize (int size)
{
if (size > (int)fdtab.size)
fdtab.extend (size);
if (size <= (int)fdtab.size || fdtab.extend (size - fdtab.size))
return 0;
return -1;
}
extern "C" int