Fixed deinitialisation bug
This commit is contained in:
parent
20cae4b6e0
commit
2d4acf9572
1 changed files with 2 additions and 2 deletions
|
|
@ -18,15 +18,15 @@ pub fn main() !void {
|
|||
const deinit_status = gpa.deinit();
|
||||
//fail test; can't try in defer as defer is executed after we return
|
||||
if (deinit_status == .leak) {
|
||||
std.log.err("memory leak ", .{});
|
||||
std.log.err("memory leak", .{});
|
||||
}
|
||||
}
|
||||
var allocator = gpa.allocator();
|
||||
|
||||
var tty = try vaxis.Tty.init();
|
||||
defer tty.deinit();
|
||||
var vx = try vaxis.init(allocator, .{});
|
||||
defer vx.deinit(allocator, tty.anyWriter());
|
||||
defer tty.deinit();
|
||||
|
||||
var topic_screen: TopicScreen = try TopicScreen.init(&allocator, &tty, &vx);
|
||||
var screen_interface = topic_screen.screenInterface();
|
||||
|
|
|
|||
Loading…
Reference in a new issue