The standard input stream
#include <stdio.h> FILE * stdin;
This global variable defines the standard input stream. It's set to the console by default, but you can redirect it by calling freopen().
STDIN_FILENO, which is defined in <unistd.h>, defines the file descriptor that corresponds to stdin.
Last modified: 2013-09-30