summaryrefslogtreecommitdiff
path: root/src/fs.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/fs.zig')
-rw-r--r--src/fs.zig7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/fs.zig b/src/fs.zig
index 4a243b10..7a56d387 100644
--- a/src/fs.zig
+++ b/src/fs.zig
@@ -1636,6 +1636,11 @@ pub const Namespace = struct {
/// a close through a mount may not wait for the editor to be quiet,
/// as 9ns answers nothing else on that mount while a clunk is out.
pages: std.ArrayList(struct { serial: u32, bytes: std.ArrayList(u8) }) = .empty,
+ /// The last line each closed open wrote with no newline after it, with
+ /// the node it was written to, for the editor's step to run
+ /// (tree.runClosedLines): a close is answered at once, for the same
+ /// reason as `pages`.
+ closed_lines: std.ArrayList(struct { node: u64, bytes: std.ArrayList(u8) }) = .empty,
batch: struct {
serial: u32 = 0,
node: u64 = 0,
@@ -1685,6 +1690,8 @@ pub const Namespace = struct {
for (&st.opens) |*o| o.deinit(gpa);
for (st.pages.items) |*page| page.bytes.deinit(gpa);
st.pages.deinit(gpa);
+ for (st.closed_lines.items) |*line| line.bytes.deinit(gpa);
+ st.closed_lines.deinit(gpa);
st.log.deinit(gpa);
st.out.deinit(gpa);
}