diff options
author | Marvin Borner | 2020-01-04 23:30:28 +0100 |
---|---|---|
committer | Marvin Borner | 2020-01-04 23:30:28 +0100 |
commit | 527d8bfeffa41086ad4e0c257b27e8c916fd514c (patch) | |
tree | d5d94bc43c8d8bd091ec5b3296b13e4c640290ce /src/kernel/system.c | |
parent | e015aeacf14c1ec50ca14dda01c760dc16b26506 (diff) |
Removed hardcoded line numbers
Wasn't that hard after all, eh?
Diffstat (limited to 'src/kernel/system.c')
-rw-r--r-- | src/kernel/system.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/kernel/system.c b/src/kernel/system.c index ada1750..f7c7fc8 100644 --- a/src/kernel/system.c +++ b/src/kernel/system.c @@ -18,7 +18,9 @@ void vga_clear() terminal_buffer[y * 80 + x] = 0 | (uint16_t) 0x700; } -void vga_log(char *msg, int line) +static line = 0; + +void vga_log(char *msg) { if (line == 0) vga_clear(); uint16_t *terminal_buffer = (uint16_t *) 0xB8000; @@ -32,6 +34,7 @@ void vga_log(char *msg, int line) strcat(string, msg); strcat(string, "\n"); strcat(vga_buffer, string); + line++; } void kernel_time() |