From a1e58e8ee1c84b633d6d6d651d5328d4dd4eba5b Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Tue, 8 Sep 2015 18:43:11 +0200 Subject: tree-wide: use coccinelle to patch a lot of code to use mfree() This replaces this: free(p); p = NULL; by this: p = mfree(p); Change generated using coccinelle. Semantic patch is added to the sources. --- src/core/dbus-execute.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'src/core/dbus-execute.c') diff --git a/src/core/dbus-execute.c b/src/core/dbus-execute.c index 3c98a0b186..ed55fcfca2 100644 --- a/src/core/dbus-execute.c +++ b/src/core/dbus-execute.c @@ -786,8 +786,7 @@ int bus_exec_context_set_transient_property( if (mode != UNIT_CHECK) { if (isempty(uu)) { - free(c->user); - c->user = NULL; + c->user = mfree(c->user); } else { char *t; @@ -814,8 +813,7 @@ int bus_exec_context_set_transient_property( if (mode != UNIT_CHECK) { if (isempty(gg)) { - free(c->group); - c->group = NULL; + c->group = mfree(c->group); } else { char *t; -- cgit v1.2.3-54-g00ecf