Used ring buffer for telemetry events buffer

This commit is contained in:
Nikolay Govorov
2026-03-16 23:22:25 +00:00
parent b14ae02548
commit 5fb561dc9c
4 changed files with 155 additions and 106 deletions

View File

@@ -67,7 +67,7 @@ pub fn init(allocator: Allocator, config: *const Config) !*App {
app.app_dir_path = getAndMakeAppDir(allocator);
app.telemetry = try Telemetry.init(app, config.mode);
errdefer app.telemetry.deinit();
errdefer app.telemetry.deinit(allocator);
app.arena_pool = ArenaPool.init(allocator, 512, 1024 * 16);
errdefer app.arena_pool.deinit();
@@ -85,7 +85,7 @@ pub fn deinit(self: *App) void {
allocator.free(app_dir_path);
self.app_dir_path = null;
}
self.telemetry.deinit();
self.telemetry.deinit(allocator);
self.network.deinit();
self.snapshot.deinit();
self.platform.deinit();