file-system: the mount-failure log has no scratch buffer (orphaned bounds fix)

The mount-failure diagnostic wrote through a fixed [96]u8 bufPrint buffer,
which the bounds gate flags as an undeclared ceiling. Three ring appends
instead — no buffer, no fixed length to justify. This fix was made during
the V2a bounds work but never git-added, so the committed harness still
carried the flagged buffer; committing it now cleans the tip.
This commit is contained in:
Daniel Samson
2026-08-09 19:40:39 +01:00
parent 7c6ed2ca09
commit b9058fe020
+5 -2
View File
@@ -310,8 +310,11 @@ pub fn Server(comptime Engine: type) type {
// The failure diagnostic goes to the kernel ring directly, not
// through std.log — the mount that failed may be /system/logs
// itself, and a routed record would then have nowhere to land.
var line: [96]u8 = undefined;
_ = logging.write(std.fmt.bufPrint(&line, "file-system: could not mount {s}\n", .{m.prefix}) catch "file-system: a mount failed\n");
// Three appends rather than a formatted line so there is no
// scratch buffer (and so no fixed length to justify).
_ = logging.write("file-system: could not mount ");
_ = logging.write(m.prefix);
_ = logging.write("\n");
}
}
mounted = true;