diff options
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/logger/log.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/lib/logger/log.c b/lib/logger/log.c index d591b36..5350eda 100644 --- a/lib/logger/log.c +++ b/lib/logger/log.c @@ -5,7 +5,6 @@ #include <stdbool.h> #include "kernel/kernel.h" -#include "kernel/config.h" #include "kernel/timer.h" #include "kernel/fifo.h" @@ -13,10 +12,8 @@ static void log_string(char *str) { - while(*str!=0) - { - fifo_put(&get_fool()->std_out,*(str++)); - } + if(get_max_fd()<2)return; +// syscall_write(2,str,strlen(str)); } void log(char *module_name, int log_level, char *format_string, ...) @@ -52,7 +49,9 @@ void panic(char *module_name, char *message) { char buf_log[256]; tfp_sprintf(buf_log,"\033[41;37m\n !! KERNEL PANIC !! %s: %s\n\n",module_name,message); - log_string(buf_log); +// log_string(buf_log); + //PANIC DIRECTLY TO STDOUT// + syscall_write(1,buf_log,strlen(buf_log)); while(1) { |
