river-status: fix memory leak

This commit is contained in:
Isaac Freund 2020-06-19 14:48:28 +02:00
parent 12d34d4ded
commit 2ef8261493
No known key found for this signature in database
GPG key ID: 86DED400DDFD7A11

View file

@ -53,6 +53,7 @@ fn handleResourceDestroy(wl_resource: ?*c.wl_resource) callconv(.C) void {
const self = util.voidCast(Self, c.wl_resource_get_user_data(wl_resource).?);
const node = @fieldParentPtr(std.SinglyLinkedList(Self).Node, "data", self);
self.seat.status_trackers.remove(node);
util.gpa.destroy(node);
}
fn destroy(wl_client: ?*c.wl_client, wl_resource: ?*c.wl_resource) callconv(.C) void {