From 3fc977d7dad2822c15a0d4171bb3c237d62e1e0d Mon Sep 17 00:00:00 2001 From: Antonin Décimo Date: Fri, 9 Aug 2019 15:31:33 +0200 Subject: Fix memory leak --- types/wlr_data_control_v1.c | 1 + 1 file changed, 1 insertion(+) diff --git a/types/wlr_data_control_v1.c b/types/wlr_data_control_v1.c index d21a6ba1..4b1c87fc 100644 --- a/types/wlr_data_control_v1.c +++ b/types/wlr_data_control_v1.c @@ -300,6 +300,7 @@ static struct wl_resource *create_offer(struct wlr_data_control_device_v1 *devic struct wl_resource *resource = wl_resource_create(client, &zwlr_data_control_offer_v1_interface, version, 0); if (resource == NULL) { + free(offer); return NULL; } -- cgit v1.2.3