[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: OpenVMS getdtablesize.c

From: John E. Malmberg
Subject: Re: OpenVMS getdtablesize.c
Date: Tue, 11 Jul 2017 08:12:48 -0500
User-agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.2.0

On 6/28/2017 3:56 PM, Bruno Haible wrote:
John E. Malmberg wrote:
OpenVMS has the function.  Configure detects it exists, but the test for
it working is failing.
The OpenVMS getdtablesize() is returning the maximum number of open
files that a process can have.

It is not returning the highest file descriptor + 1 that can be used in
the system.  That number is 65535 for OpenVMS Alpha and Integrity.

That is why it is failing the configure test.

There are two possibilities:
   (a) change the configure test so that is duplicates
       fd 0 to 1, 2, 3, ..., getdtablesize() and see if that fails.
   (b) special-case OpenVMS.

I'm not in favour of (a) because it might allocate so many file descriptors
that the kernel gets problems.

So (b). Just add a few lines

   case "$host_os" in
     vms*) ...

at the appropriate place. Can you propose such a patch?

Please try to approximate the wording of POSIX [1] as closely as possible.


[1] http://pubs.opengroup.org/onlinepubs/9699919799/functions/getrlimit.html
According to that link, a system is not required to fail a request for a file descriptor to be created higher than RLIMIT_NOFILE.

Attached is a patch for the test to pass on OpenVMS.


Attachment: 0001-getdtablesize.m4-Fix-for-OpenVMS.patch.gz
Description: GNU Zip compressed data

reply via email to

[Prev in Thread] Current Thread [Next in Thread]