summaryrefslogtreecommitdiff
path: root/src/kernel/log.c
diff options
context:
space:
mode:
authorBenji Dial <benji6283@gmail.com>2021-02-18 11:56:08 -0500
committerBenji Dial <benji6283@gmail.com>2021-02-18 11:56:08 -0500
commit00cc8736f10098dedf6b856b9ad8bd0094211263 (patch)
tree4cd252a614b26cb3dcf4a20c142feeffbb4c3c2a /src/kernel/log.c
parent9d8ce7688f051fc5cd9e917faf3b1e49a3e620ab (diff)
downloadportland-os-00cc8736f10098dedf6b856b9ad8bd0094211263.tar.gz
vbe support, truecolor window manager pixbufs
Diffstat (limited to 'src/kernel/log.c')
-rw-r--r--src/kernel/log.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/kernel/log.c b/src/kernel/log.c
index 6bad1cc..2819a2e 100644
--- a/src/kernel/log.c
+++ b/src/kernel/log.c
@@ -52,8 +52,16 @@ void logf(enum log_level level, const char *format, ...) {
while (*s)
logch(*(s++));
break;
+ case 'n':;
+ uint32_t d = va_arg(args, uint32_t);
+ if (d >= 0x80000000) {
+ logch('-');
+ d = -d;
+ }
+ goto put_dec;
case 'd':;
- const uint32_t d = va_arg(args, uint32_t);
+ d = va_arg(args, uint32_t);
+ put_dec:
if (d == 0) {
logch('0');
break;