]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/basic/env-util.c
env-util: fix parameter handling of parse_env_extension_hierarchies() + getenv_path_l...
authorLennart Poettering <lennart@poettering.net>
Thu, 25 Feb 2021 12:16:36 +0000 (13:16 +0100)
committerLennart Poettering <lennart@poettering.net>
Thu, 25 Feb 2021 12:24:53 +0000 (13:24 +0100)
commit33d31c0e60502a926e68b653055a4744166c5e3d
tree7b50f70386fa013e31d19c4097c1446e58c2a073
parent9c274488a9168f8284dc99882856ca79ce2aa132
env-util: fix parameter handling of parse_env_extension_hierarchies() + getenv_path_list()

Our coding style dictates we should not clobber return parameters on
failure, and always initialize them on success. Do so here.

This changes getenv_path_list() to return ENXIO if the env var is not
set, which is similar to how we handle this in getenv_bool().

This drops debug logging from parse_env_extension_hierarchies(), since
it's done anyway in getenv_path_list()

Follow-up for: #18018
src/basic/env-util.c
src/shared/extension-release.c