summaryrefslogtreecommitdiff
path: root/src/core/dbus-execute.c
diff options
context:
space:
mode:
authorRonny Chevalier <rchevalier@aldebaran-robotics.com>2013-07-25 17:36:01 +0200
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2013-08-08 00:21:33 -0400
commit68eda4bd168306f51c90e5d22824c494d709289e (patch)
treed7d293b0800a0971c01a6102355e31ab731561b6 /src/core/dbus-execute.c
parentf058ccf2cdc20ff9ad986e84727d2cf43c51a0ef (diff)
dbus: use _cleanup_free_ instead of freeing ourself
Diffstat (limited to 'src/core/dbus-execute.c')
-rw-r--r--src/core/dbus-execute.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/core/dbus-execute.c b/src/core/dbus-execute.c
index 73590c82be..2402e8c34d 100644
--- a/src/core/dbus-execute.c
+++ b/src/core/dbus-execute.c
@@ -77,12 +77,11 @@ static int bus_execute_append_oom_score_adjust(DBusMessageIter *i, const char *p
if (c->oom_score_adjust_set)
n = c->oom_score_adjust;
else {
- char *t;
+ _cleanup_free_ char *t = NULL;
n = 0;
if (read_one_line_file("/proc/self/oom_score_adj", &t) >= 0) {
safe_atoi(t, &n);
- free(t);
}
}