fix(gui): fix resize crash
This commit is contained in:
parent
4ca31b0f75
commit
091345fd02
1 changed files with 3 additions and 0 deletions
|
|
@ -213,6 +213,9 @@ pub const WindowState = struct {
|
||||||
c.deinit(global.glyph_cache_arena.allocator());
|
c.deinit(global.glyph_cache_arena.allocator());
|
||||||
_ = global.glyph_cache_arena.reset(.retain_capacity);
|
_ = global.glyph_cache_arena.reset(.retain_capacity);
|
||||||
state.glyph_index_cache = null;
|
state.glyph_index_cache = null;
|
||||||
|
// cell_buf was allocated from the arena; clear it so the next
|
||||||
|
// resize doesn't memcpy from the now-freed memory.
|
||||||
|
state.cell_buf = .{};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue