mirror of
https://github.com/Mathewnd/Astral.git
synced 2026-11-02 07:28:21 +00:00
printing: \n -> \n\r on printf
This commit is contained in:
@@ -29,6 +29,9 @@ size_t console_ttywrite(void *internal, char *str, size_t count) {
|
||||
}
|
||||
|
||||
void console_putc(char c) {
|
||||
if (c == '\n')
|
||||
console_write("\n\r", 2);
|
||||
else
|
||||
console_write(&c, 1);
|
||||
}
|
||||
|
||||
|
||||
@@ -47,6 +47,9 @@ void term_write(char *str, size_t count) {
|
||||
}
|
||||
|
||||
void term_putchar(char c) {
|
||||
if (c == '\n')
|
||||
flanterm_write(term_ctx, "\n\r", 2);
|
||||
else
|
||||
flanterm_write(term_ctx, &c, 1);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user