]> git.ipfire.org Git - people/ms/strongswan.git/commitdiff
leak-detective: Use passed callback to report leaks
authorTobias Brunner <tobias@strongswan.org>
Mon, 20 Apr 2015 09:19:52 +0000 (11:19 +0200)
committerTobias Brunner <tobias@strongswan.org>
Mon, 20 Apr 2015 09:22:55 +0000 (11:22 +0200)
This prevented `stroke memusage` from reporting the leaks on the
console.  Instead, they were sent to the callbacks set up by libstrongswan.

Fixes a426851f6362 ("leak-detective: Use callback functions to report
leaks and usage information").

src/libstrongswan/utils/leak_detective.c

index e4cd3d7d6472ebd6a74548922ab08a4e499853ea..99f4843ad6c61112c8207f33089afbd84ad67b98 100644 (file)
@@ -691,8 +691,8 @@ static int print_traces(private_leak_detective_t *this,
                        {
                                if (!thresh_count || entry->count >= thresh_count)
                                {
-                                       this->report_cb(this->report_data, entry->count,
-                                                                       entry->bytes, entry->backtrace, detailed);
+                                       cb(user, entry->count, entry->bytes, entry->backtrace,
+                                          detailed);
                                }
                        }
                }