summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/dump.zig7
-rw-r--r--core/fuzz.zig4
-rw-r--r--core/replica.zig2
3 files changed, 9 insertions, 4 deletions
diff --git a/core/dump.zig b/core/dump.zig
index 0cefa157..a2b22cef 100644
--- a/core/dump.zig
+++ b/core/dump.zig
@@ -381,9 +381,12 @@ pub fn check(gpa: std.mem.Allocator, bytes: []const u8, why: *[256]u8) !void {
/// The core the dump `bytes` is, and nothing more: no shell started, no
/// file watched, nothing asked of a host (`revive` does that). What another
/// build's dump could not give is said in `notes` when given. `opts` are
-/// this process's (its allocators, paths and name), not the dump's.
+/// this process's (its allocators, paths and name), not the dump's. Its
+/// chrome is the restored theme's: the colours are local, never dumped.
pub fn load(gpa: std.mem.Allocator, opts: Options, bytes: []const u8, notes: ?*std.ArrayList(u8)) !*Pardes {
- return loadKnowing(gpa, opts, bytes, notes, null);
+ const p = try loadKnowing(gpa, opts, bytes, notes, null);
+ colors.finishThemeInitialization(p);
+ return p;
}
/// `load`, with which panes' files were on disk when it was dumped.
diff --git a/core/fuzz.zig b/core/fuzz.zig
index 56ded66b..d8df1d9a 100644
--- a/core/fuzz.zig
+++ b/core/fuzz.zig
@@ -824,6 +824,10 @@ test "a dump and an image cut, flipped and grown: refused or loaded, never a pan
// `live` (the core read in place, its own `live` undefined), a live
// message's `src` length 0xAAAA when the digest walked it.
try loadSeed(bytes, .join, 6356);
+ // Join seed 8324: `debug` read on, and the overlay printed the theme's
+ // name from the chrome, which the load had never worked out (a join's
+ // caller did, after it): the old names' view's name 0xAAAA.
+ try loadSeed(bytes, .join, 8324);
for ([_][]const u8{ bytes, described, image }, [_]Road{ .join, .join, .restore }, [_]u64{ 2048, 2048, 1024 }) |whole, road, n| {
try loadSeed(whole, road, 0);
for (1..n + 1) |seed| try loadSeed(whole, road, seed);
diff --git a/core/replica.zig b/core/replica.zig
index 6c037cd2..49ccd85b 100644
--- a/core/replica.zig
+++ b/core/replica.zig
@@ -588,8 +588,6 @@ pub const Replica = struct {
r.view = Peers.viewFor(c, null, true) orelse return error.NoView;
break :boot c;
};
- // The chrome's colours are local, never dumped: the restored theme's.
- if (dump != null) pardes.colors.finishThemeInitialization(c);
// It runs a plain kind's code of its own (Addon.plainOps), loaded
// at its first pane, each opened here from its record; another's
// panes show a line.