@@ -5,9 +5,12 @@
5#include <fcntl.h>
5#include <fcntl.h>
6#include <stdio.h>
6#include <stdio.h>
7#include <time.h>
7#include <time.h>
9extern char** environ;
10extern char** environ;
12+int win_fpoll(void* h);
11void putStr(char* str) {
14void putStr(char* str) {
12 printf("%s", str);
15 printf("%s", str);
@@ -32,14 +35,18 @@ int fileError(void* h) {
32 return ferror(f);
35 return ferror(f);
35−void fputStr(void* h, char* str) {
38+int idris_writeStr(void* h, char* str) {
36 FILE* f = (FILE*)h;
39 FILE* f = (FILE*)h;
37− fputs(str, f);
40+ if (fputs(str, f)) {
40int fpoll(void* h)
47int fpoll(void* h)
42− return 0;
49+ return win_fpoll(h);
45void* do_popen(const char* cmd, const char* mode) {
52void* do_popen(const char* cmd, const char* mode) {