]> git.ipfire.org Git - thirdparty/systemd.git/commit
Refactor strv_env_replace() into strv_env_replace_consume() 18601/head
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 16 Feb 2021 15:04:41 +0000 (16:04 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 16 Feb 2021 15:10:14 +0000 (16:10 +0100)
commit13734c75b58898d079867e959c8bc572d0ec75d6
tree9a78e08baa9a2981d2df0599a548e5b965a292c3
parentb230baaeb76dd1f3b6c991257331fc816ee7827b
Refactor strv_env_replace() into strv_env_replace_consume()

All callers of strv_env_replace() would free the argument on error.
So let's follow the same pattern as with strv_consume (and similar
naming) and unconditionally "use up" the argument.
src/basic/env-file.c
src/basic/env-util.c
src/basic/env-util.h
src/core/load-fragment.c
src/shared/serialize.c