]> git.sesse.net Git - cubemap/blobdiff - util.cpp
Implement much better logging, with support for both files and syslog.
[cubemap] / util.cpp
index b79c6c3dccd5e0a58ca2f25a09b28c6d223bdd64..41c13c6f2a3ed743a5345b3d0d41c37aefb6e5bc 100644 (file)
--- a/util.cpp
+++ b/util.cpp
@@ -4,6 +4,7 @@
 #include <stdlib.h>
 #include <unistd.h>
 
+#include "log.h"
 #include "util.h"
 
 using namespace std;
@@ -68,7 +69,7 @@ bool read_tempfile(int fd, std::string *contents)
                        goto done;
                }
                if (ret == 0) {
-                       fprintf(stderr, "Unexpected EOF!\n");
+                       log(ERROR, "Unexpected EOF!");
                        ok = false;
                        goto done;
                }