Name

getdtablesize - get descriptor table size

Library

libc.lib

Synopsis

  #include <unistd.h>
  int getdtablesize (void);

Return values


Detailed description

Each process has a fixed size descriptor table, which is guaranteed to have at least 20 slots. The entries in the descriptor table are numbered with small integers starting at 0. The getdtablesize system call returns the size of this table.

Examples

#include <stdio.h>
int main()
{
        printf("maximum number of files that can be opened by a process is %d\n",getdtablesize());
}

         

Output

maximum number of files that can be opened by a process is 1024

         

See also

close, dup, open

Feedback

For additional information or queries on this page send feedback

© 2005-2007 Nokia

Top