summaryrefslogtreecommitdiffstats
path: root/src/shared/conf-parser.h
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2024-02-21 22:29:56 +0100
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2024-03-07 18:49:44 +0100
commitd8a91c6b9f64017abfefbbf7da0daed590de372a (patch)
treede505554b6565bba9cea4bd4b69aa2503181da38 /src/shared/conf-parser.h
parentstrv: add helper to extend strv from both sides (diff)
downloadsystemd-d8a91c6b9f64017abfefbbf7da0daed590de372a.tar.xz
systemd-d8a91c6b9f64017abfefbbf7da0daed590de372a.zip
shared/conf-parser: use chase() in config_parse_many_files()
The function was partially implementing chroot lookups. It would be given file names that were prefixed with the chroot, so it would mostly work. But if any of those files were symlinks, fopen() would do the wrong thing. Also we don't need locking. So give 'root' as the argument and use chase_and_fopen_unlocked() to get proper chroot-aware lookups. The only place where config_parse_many() is called with root is is repart.c. So this is a follow-up for e594a3b154bd06c535a934a1cc7231b1ef76df73 and 34f2fd5096cdb26ef57998740b1b876332d968fc.
Diffstat (limited to '')
-rw-r--r--src/shared/conf-parser.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shared/conf-parser.h b/src/shared/conf-parser.h
index 2c75ba5d8b..9d08cbd677 100644
--- a/src/shared/conf-parser.h
+++ b/src/shared/conf-parser.h
@@ -106,7 +106,7 @@ int config_parse_many(
const char* const* conf_file_dirs,
const char *dropin_dirname,
const char *root,
- const char *sections, /* nulstr */
+ const char *sections, /* nulstr */
ConfigItemLookup lookup,
const void *table,
ConfigParseFlags flags,