returns the file descriptor associated with the directory stream
This descriptor is the one used internally by the directory stream.
As a result, it is only useful for functions which do not depend on
or alter the file position, such as
It will be automatically closed when
On success, a nonnegative file descriptor is returned.
On error, -1 is returned.
POSIX.1-2008 specifies two errors,
neither of which is returned by the current
does not refer to a valid directory stream.
The implementation does not support the association of a file
descriptor with a directory.
This function was a BSD extension, present in 4.3BSD-Reno, not in 4.2BSD.
The prototype for
is only available if