From fcdf1a1ff156b6855f68bc738e746f4b7825c020 Mon Sep 17 00:00:00 2001 From: Benjamin Berg Date: Mon, 23 Dec 2019 23:55:55 +0100 Subject: [PATCH] device: Fix potential memory leak of progress_cb user data The progress report user data free func was not assigned and therefore never called. Add the missing assign, potentially fixing memory leaks (mostly relevant for bindings). --- libfprint/fp-device.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libfprint/fp-device.c b/libfprint/fp-device.c index 116f9f87..634c2cc1 100644 --- a/libfprint/fp-device.c +++ b/libfprint/fp-device.c @@ -775,6 +775,7 @@ fp_device_enroll (FpDevice *device, data->print = g_object_ref_sink (template_print); data->enroll_progress_cb = progress_cb; data->enroll_progress_data = progress_data; + data->enroll_progress_destroy = progress_destroy; // Attach the progress data as task data so that it is destroyed g_task_set_task_data (priv->current_task, data, (GDestroyNotify) enroll_data_free);