summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2017-12-07 22:16:16 +0100
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2017-12-15 14:57:07 +0100
commit8426bfd397d5aba61c9b5ec79c12864ccf4cfd58 (patch)
treeb74ae0b468b955aa6759518bc5707d61725cd644 /src
parente5af6e0e2d545c7fd29b9b8abd749bd3994b5bf8 (diff)
downloadsystemd-8426bfd397d5aba61c9b5ec79c12864ccf4cfd58.tar.gz
systemd-8426bfd397d5aba61c9b5ec79c12864ccf4cfd58.tar.bz2
systemd-8426bfd397d5aba61c9b5ec79c12864ccf4cfd58.zip
logind: use free_and_replace in one spot
No functional change.
Diffstat (limited to 'src')
-rw-r--r--src/login/logind-user.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/login/logind-user.c b/src/login/logind-user.c
index 00c2a22490..32b2045696 100644
--- a/src/login/logind-user.c
+++ b/src/login/logind-user.c
@@ -527,9 +527,7 @@ static int user_stop_service(User *u) {
return r;
}
- free(u->service_job);
- u->service_job = job;
-
+ free_and_replace(u->service_job, job);
return r;
}