DragonFlyBSD Kernel Audit
DF-2045 / fix.diff
← back to finding ↓ download raw
--- /tmp/orig/dev/misc/syscons/schistory.c	2026-07-23 11:54:56.874861000 +0000
+++ dev/misc/syscons/schistory.c	2026-07-23 12:03:00.709700000 +0000
@@ -154,6 +154,8 @@
 			sc_vtb_destroy(history);
 			kfree(history, M_SYSCONS);
 		}
+		if (lines > min_lines)
+			extra_history_size += lines - min_lines;
 		scp->history_pos = 0;
 		scp->history = prev_history;
 	}