From: Robert Pengelly Date: Sun, 18 Oct 2026 11:45:07 +0000 (+0100) Subject: Initialize BIOS video before executing DOS applications X-Git-Url: https://git.candlhat.org/?a=commitdiff_plain;h=e117e69b6792fef9551e3cd4a10e0f3ac0be9c6c;p=dosemu.git Initialize BIOS video before executing DOS applications --- diff --git a/interrupts.c b/interrupts.c index 4502012..697a584 100644 --- a/interrupts.c +++ b/interrupts.c @@ -6257,8 +6257,14 @@ static void int_10 (CPU8086 *cpu) { fputs ("\0337\033[?7l", stdout); bios_video_set_attribute ((uint8_t) cpu->regs[REG_BX]); - for (i = 0; i < count; i++) { - bios_write_video_char (al); + if (bios_cursor_row[0] < 25 && bios_cursor_col[0] < 80) { + + fprintf (stdout, "\033[%u;%uH", (unsigned) bios_cursor_row[0] + 1, (unsigned) bios_cursor_col[0] + 1); + + for (i = 0; i < count && (unsigned) bios_cursor_col[0] + i < 80; i++) { + bios_write_video_char (al); + } + } fputs ("\033[0m\033[?7h\0338", stdout); @@ -6564,6 +6570,8 @@ void init_ivt (CPU8086 *cpu) { file_handles[0] = stdin; file_handles[1] = stdout; file_handles[2] = stderr; + + bios_video_initialize (); }