diff options
Diffstat (limited to 'lib/logger')
| -rw-r--r-- | lib/logger/log.c | 5 | ||||
| -rw-r--r-- | lib/logger/log.h | 7 |
2 files changed, 6 insertions, 6 deletions
diff --git a/lib/logger/log.c b/lib/logger/log.c index 55622c0..aea1b7f 100644 --- a/lib/logger/log.c +++ b/lib/logger/log.c @@ -1,10 +1,11 @@ #include "log.h" - +#include <stdarg.h> void PutConsole(char *str, int color, va_list va); -void log(char *module_name, int prio, char *format_string, ...) +void log(char *module_name, int log_level, char *format_string, ...) { + if(log_level<FOOLOS_LOG_INFO)return; PutConsole(module_name,0b1111100000000000,0); PutConsole(": ",0b0000011111100000,0); diff --git a/lib/logger/log.h b/lib/logger/log.h index bcc1bc7..9c32a39 100644 --- a/lib/logger/log.h +++ b/lib/logger/log.h @@ -1,10 +1,9 @@ #ifndef FOOLOS_LOG_H #define FOOLOS_LOGL_H - -#define FOOLOS_LOG_INFO 1 - -#include <stdarg.h> +#define FOOLOS_LOG_INFO 3 +#define FOOLOS_LOG_DEBUG 2 +#define FOOLOS_LOG_FINE 1 void log(char *module_name, int prio, char *format_string, ...); |
