Yes, the file numbers for STDIN / STDOUT and STDERR behave the same also on Windows. unistd.h defines them to be 0, 1 and 2 respectively.
Beware though that if you close one of the three, the file numbers may be reallocated to other filehandles.
In reply to Re^3: Testing whether a file handle is attached to STDOUT
by Corion
in thread Testing whether a file handle is attached to STDOUT
by rovf
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |