fix compiler warnings

This commit is contained in:
Quinten Kock 2020-12-04 02:36:47 +01:00
parent e3d032e84e
commit a32fdffde6
4 changed files with 6 additions and 6 deletions

View File

@ -30,7 +30,7 @@ void vga_putc(char c) {
} }
} }
void vga_puts(char *c) { void vga_puts(const char *c) {
char cur = *(c++); char cur = *(c++);
while(cur != '\0') { while(cur != '\0') {
vga_putc(cur); vga_putc(cur);
@ -42,7 +42,7 @@ void vga_setcolor(uint8_t new_color) {
current_color = new_color; current_color = new_color;
} }
void vga_write_elsewhere(char *c, size_t y, size_t x) { void vga_write_elsewhere(const char *c, size_t y, size_t x) {
size_t old_row = terminal_row; size_t old_row = terminal_row;
size_t old_column = terminal_column; size_t old_column = terminal_column;
terminal_row = y; terminal_row = y;

View File

@ -19,6 +19,6 @@
#define VGA_WHITE 15 #define VGA_WHITE 15
void vga_putc(char c); void vga_putc(char c);
void vga_puts(char *c); void vga_puts(const char *c);
void vga_setcolor(uint8_t color); void vga_setcolor(uint8_t color);
void vga_write_elsewhere(char *c, size_t y, size_t x); void vga_write_elsewhere(const char *c, size_t y, size_t x);

View File

@ -3,4 +3,4 @@ void halt_catch_fire() {
while(1) asm volatile ("hlt"); while(1) asm volatile ("hlt");
} }
const char *arch = "x86_64"; const char *arch = "x86_64";

View File

@ -1,3 +1,3 @@
void halt_catch_fire(); void halt_catch_fire();
extern const char *arch; extern const char *arch;