Google
 
   
Login
Username:

Password:


Lost Password?

Register now!
Search
Main Menu
top books
Polls
What do you think about php-deluxe.net?
Excellent!
Cool
Hmm..not bad
What the hell is this?
encyclopedia
recommendation
compare webbrowser
Freenet DSL
Who's Online
11 user(s) are online (9 user(s) are browsing encyclopedia)

Members: 0
Guests: 11

more...
browser tip
Unix Befehle
manual of unix befehle
recommendation!
Sponsored
partner

File descriptor

In Computing, a file descriptor is an identifier maintained by the operating system. It is a unique identifier identifying an open computer file. Once the file has been opened, the file descriptor can be used by different system calls to read or write it.

The term file descriptor is generally used in POSIX operating systems. In Microsoft Windows terminology and in the context of the stdio library, file handle is preferred.

In POSIX, a file descriptor is an integer, specifically of the C type int. There are 3 standard POSIX file descriptors which presumably every process (save perhaps a daemon) should expect to have:

::

Generally, a file descriptor is a key to a kernel-resident data structure containing the details of all open files. In POSIX this data structure is called a file descriptor table, and each process has its own. The user application passes the abstract key to the kernel through a system call, and the kernel will access the file on behalf of the application, based on the key. The application itself cannot read or write the file descriptor table directly.

In Unix-like system, file descriptors can refer to files, directory, block device or character devices (also called special files ), sockets, FIFOs (also called named pipes), unnamed pipes, or symbolic links.