]> git.xonotic.org Git - xonotic/gmqcc.git/blobdiff - conout.c
con_default_out for opts.pp_only (removes recently added TODO .. and fixes a segfault)
[xonotic/gmqcc.git] / conout.c
index bf8b522648802b1b342760fdd81ecb8abfce20f2..eb57d68b69d048d8332d394d99f7de1739514538 100644 (file)
--- a/conout.c
+++ b/conout.c
@@ -289,6 +289,17 @@ int con_change(const char *out, const char *err) {
     return 1;
 }
 
+/*
+ * Defaultizer because stdio.h shouldn't be used anywhere except here
+ * and inside file.c To prevent mis-match of wrapper-interfaces.
+ */ 
+void con_default_out() {
+    console.handle_out = stdout;
+}
+void con_default_err() {
+    console.handle_err = stderr;
+}
+
 int con_verr(const char *fmt, va_list va) {
     return con_write(console.handle_err, fmt, va);
 }