| title |
Low-Level I-O | Microsoft Docs |
| ms.custom |
|
| ms.date |
11/04/2016 |
| ms.reviewer |
|
| ms.suite |
|
| ms.technology |
|
| ms.tgt_pltfrm |
|
| ms.topic |
article |
| f1_keywords |
|
| dev_langs |
|
| helpviewer_keywords |
I/O [CRT], low-level |
I/O [CRT], functions |
low-level I/O routines |
file handles [C++] |
file handles [C++], I/O functions |
|
| ms.assetid |
53e11bdd-6720-481c-8b2b-3a3a569ed534 |
| caps.latest.revision |
9 |
| author |
corob-msft |
| ms.author |
corob |
| manager |
ghogen |
| translation.priority.ht |
cs-cz |
de-de |
es-es |
fr-fr |
it-it |
ja-jp |
ko-kr |
pl-pl |
pt-br |
ru-ru |
tr-tr |
zh-cn |
zh-tw |
|
These functions invoke the operating system directly for lower-level operation than that provided by stream I/O. Low-level input and output calls do not buffer or format data.
Low-level routines can access the standard streams opened at program startup using the following predefined file descriptors.
| Stream |
File Descriptor |
stdin |
0 |
stdout |
1 |
stderr |
2 |
Low-level I/O routines set the errno global variable when an error occurs. You must include STDIO.H when you use low-level functions only if your program requires a constant that is defined in STDIO.H, such as the end-of-file indicator (EOF).
_dup and _dup2 are typically used to associate the predefined file descriptors with different files.
Input and Output
Run-Time Routines by Category
System Calls