From 5a93a1b8033f8dae0c616fea459572c7a3c346f4 Mon Sep 17 00:00:00 2001 From: ptrcnull Date: Wed, 15 Nov 2023 02:33:16 +0100 Subject: [PATCH] fix the memleak --- src/main.zig | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main.zig b/src/main.zig index 748dbf8..f0fe25e 100644 --- a/src/main.zig +++ b/src/main.zig @@ -99,6 +99,7 @@ pub fn main() !void { if (ret == c.FALSE) { std.log.err("failed to send a notification: {s}", .{g_err.*.message}); } + c.g_object_unref(c.G_OBJECT(notif)); std.log.info("[NOTIFY] battery running low!", .{}); }