Next Previous Contents

## 3.61 fileno

> Function

>   Return the file handle used by a stream.

> Header

>   `stdio.h`

> Declaration

>   `int __fastcall__ fileno (FILE* f);`

> Description

>   The `fileno` function returns the file handle used internally by a C stream. This file handle (an integer) can be used as a handle for the POSIX input/output functions.

> Limits

>   - The function is only available as fastcall function, so it may only be used in presence of a prototype.
>   - Mixing C file I/O functions and POSIX file I/O functions for the same file may have unpredictable results.
> Availability

>   POSIX 1003.1

> See also

>   creat, open

> Example

>   None.

Next Previous Contents