From 3daf3d53a3564ba33c6043fc50e7a95b75cabef5 Mon Sep 17 00:00:00 2001 From: Bananymous Date: Fri, 17 Nov 2023 18:56:02 +0200 Subject: [PATCH] Kernel: Serial now uses random size for some serial ports If the serial port doesn't repond with a size, just use a random one. There is no reason to ditch the whole output if you cannot determine its size. --- kernel/kernel/Terminal/Serial.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/kernel/kernel/Terminal/Serial.cpp b/kernel/kernel/Terminal/Serial.cpp index 042bf4c9..877c90c6 100644 --- a/kernel/kernel/Terminal/Serial.cpp +++ b/kernel/kernel/Terminal/Serial.cpp @@ -57,7 +57,11 @@ namespace Kernel auto& driver = s_serial_drivers[i]; driver.m_port = s_serial_ports[i]; if (!driver.initialize_size()) - continue; + { + // if size detection fails, just use some random size + driver.m_width = 999; + driver.m_height = 999; + } count++; } }