diff options
author | Yunchih Chen <yunchih.cat@gmail.com> | 2018-03-18 11:04:36 +0800 |
---|---|---|
committer | Yunchih Chen <yunchih.cat@gmail.com> | 2018-03-18 11:04:36 +0800 |
commit | 5d402a894492b3b8b8c511454374f4f38260bb0f (patch) | |
tree | 1b4074c3d6ac4a9f09b10fdada273f1f1495d1fd | |
parent | 0b41d9d0b4cbc761ffbcd2a8f56b1749b1f42ed4 (diff) | |
download | nfcollect-5d402a894492b3b8b8c511454374f4f38260bb0f.tar nfcollect-5d402a894492b3b8b8c511454374f4f38260bb0f.tar.gz nfcollect-5d402a894492b3b8b8c511454374f4f38260bb0f.tar.bz2 nfcollect-5d402a894492b3b8b8c511454374f4f38260bb0f.tar.lz nfcollect-5d402a894492b3b8b8c511454374f4f38260bb0f.tar.xz nfcollect-5d402a894492b3b8b8c511454374f4f38260bb0f.tar.zst nfcollect-5d402a894492b3b8b8c511454374f4f38260bb0f.zip |
Add usefull prefix to debug output
-rw-r--r-- | include/main.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/include/main.h b/include/main.h index 4f0aa20..2203e38 100644 --- a/include/main.h +++ b/include/main.h @@ -53,18 +53,18 @@ #define FATAL(format, ...) \ do { \ - fprintf(stdout, "Error: " format "\n", ##__VA_ARGS__); \ + fprintf(stdout, "[ERROR] " format "\n", ##__VA_ARGS__); \ exit(1); \ } while(0) #define WARN(command, format, ...) \ if (command) { \ - fprintf(stdout, format "\n", ##__VA_ARGS__); \ + fprintf(stdout, "[WARN] " format "\n", ##__VA_ARGS__); \ } #define WARN_RETURN(command, format, ...) \ if (command) { \ - fprintf(stdout, format "\n", ##__VA_ARGS__); \ + fprintf(stdout, "[WARN] " format "\n", ##__VA_ARGS__); \ return -1; \ } |