MirBSD manpage: isfdtype(3)

ISFDTYPE(3)                BSD Programmer's Manual                 ISFDTYPE(3)

NAME

     isfdtype - determine whether a file descriptor is of a specific type

SYNOPSIS

     #include <sys/stat.h>

     int
     isfdtype(int fd, int fdtype);

DESCRIPTION

     The isfdtype() function checks whether or not the file descriptor fd is
     of type fdtype.

     A list of possible file types may be found in stat(2) and the
     <sys/stat.h> include file.

RETURN VALUES

     The isfdtype() function returns 1 if fd is of type fdtype and 0 if it is
     not. If isfdtype() fails, a value of -1 is returned and the global vari-
     able errno is set to indicate the error.

ERRORS

     The following error codes may be set in errno:

     [EBADF]       fd is not a valid open file descriptor.

     [EIO]         An I/O error occurred while reading from or writing to the
                   filesystem.

SEE ALSO

     stat(2)

STANDARDS

     The isfdtype() function is expected to conform to POSIX 1003.1g.

HISTORY

     The isfdtype() function first appeared in OpenBSD 3.3.

MirBSD #10-current             October 15, 2002                              1

Generated on 2022-12-24 01:00:14 by $MirOS: src/scripts/roff2htm,v 1.113 2022/12/21 23:14:31 tg Exp $ — This product includes material provided by mirabilos.

These manual pages and other documentation are copyrighted by their respective writers; their sources are available at the project’s CVSweb, AnonCVS and other mirrors. The rest is Copyright © 2002–2022 MirBSD.

This manual page’s HTML representation is supposed to be valid XHTML/1.1; if not, please send a bug report — diffs preferred.

Kontakt / Impressum & Datenschutzerklärung