From: Zbigniew Jędrzejewski-Szmek Date: Wed, 25 Jan 2017 03:21:16 +0000 (-0500) Subject: core/dbus: fix two strv memleaks X-Git-Tag: v233~206^2~2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f0c03de85afa93d1df2bb533a46748e7f4264af6;p=thirdparty%2Fsystemd.git core/dbus: fix two strv memleaks job_dbus_path and unit_dbus_path both allocate new strings, so we should use strv_free. --- diff --git a/src/core/dbus.c b/src/core/dbus.c index 1f9bf2085f7..a3f701c0645 100644 --- a/src/core/dbus.c +++ b/src/core/dbus.c @@ -477,7 +477,7 @@ static int bus_kill_context_find(sd_bus *bus, const char *path, const char *inte } static int bus_job_enumerate(sd_bus *bus, const char *path, void *userdata, char ***nodes, sd_bus_error *error) { - _cleanup_free_ char **l = NULL; + _cleanup_strv_free_ char **l = NULL; Manager *m = userdata; unsigned k = 0; Iterator i; @@ -504,7 +504,7 @@ static int bus_job_enumerate(sd_bus *bus, const char *path, void *userdata, char } static int bus_unit_enumerate(sd_bus *bus, const char *path, void *userdata, char ***nodes, sd_bus_error *error) { - _cleanup_free_ char **l = NULL; + _cleanup_strv_free_ char **l = NULL; Manager *m = userdata; unsigned k = 0; Iterator i;