aboutsummaryrefslogtreecommitdiff
path: root/include/stdio.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/stdio.h')
-rw-r--r--include/stdio.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/stdio.h b/include/stdio.h
index 989b7fc..ab17883 100644
--- a/include/stdio.h
+++ b/include/stdio.h
@@ -14,4 +14,17 @@ int vasprintf(char **str, const char *fmt, va_list ap);
14int asprintf(char **str, const char *fmt, ...); 14int asprintf(char **str, const char *fmt, ...);
15#endif 15#endif
16 16
17#ifdef _WIN32
18#include <errno.h>
19#include <string.h>
20
21static inline void
22posix_perror(const char *s)
23{
24 fprintf(stderr, "%s: %s\n", s, strerror(errno));
25}
26
27#define perror(errnum) posix_perror(errnum)
28#endif
29
17#endif 30#endif