Workaround mingw bugs

This commit is contained in:
vitaut 2015-03-19 07:39:24 -07:00
parent f49ab8e4a9
commit a53ac7ad5c
2 changed files with 2 additions and 3 deletions

View File

@ -175,7 +175,7 @@ int test::fclose(FILE *stream) {
return ::fclose(stream);
}
int test::fileno(FILE *stream) {
int (test::fileno)(FILE *stream) {
EMULATE_EINTR(fileno, -1);
return ::FMT_POSIX(fileno(stream));
}

View File

@ -72,8 +72,7 @@ int pipe(int *pfds, unsigned psize, int textmode);
FILE *fopen(const char *filename, const char *mode);
int fclose(FILE *stream);
int fileno(FILE *stream);
int (fileno)(FILE *stream);
} // namespace test
#define FMT_SYSTEM(call) test::call