14 lines
311 B
C++
14 lines
311 B
C++
|
#include <errno.h>
|
||
|
#include <fcntl.h>
|
||
|
#include <stdio.h>
|
||
|
#include <stdlib.h>
|
||
|
|
||
|
extern "C" void initialize_libc()
|
||
|
{
|
||
|
__stderr = fopen("/dev/console", "rw");
|
||
|
if (!stderr) exit(errno);
|
||
|
__stdout = fopen("/dev/console", "rw");
|
||
|
if (!stdout) exit(errno);
|
||
|
clearerr(__stderr);
|
||
|
clearerr(__stdout);
|
||
|
}
|