diff options
author | Richard Phibel <rphibel@googlemail.com> | 2022-08-08 15:40:46 +0200 |
---|---|---|
committer | Daan De Meyer <daan.j.demeyer@gmail.com> | 2022-08-12 12:48:29 +0200 |
commit | ead3a3fc87590d91795397cfa82783a3282cdef2 (patch) | |
tree | 4e55661d93aeea54e97b8ea6f2521f3c6f759899 /src/shared/conf-parser.c | |
parent | 65c2ad985a8debdf6d7d11fee5b466f280260f4b (diff) | |
download | systemd-ead3a3fc87590d91795397cfa82783a3282cdef2.tar.gz |
config-parser: Add list of drop-in files as return argument of config_parse_many
This will be used to save the list of drop-in files for each partition
Diffstat (limited to 'src/shared/conf-parser.c')
-rw-r--r-- | src/shared/conf-parser.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/shared/conf-parser.c b/src/shared/conf-parser.c index 765ccec501..887ae0dd61 100644 --- a/src/shared/conf-parser.c +++ b/src/shared/conf-parser.c @@ -588,7 +588,8 @@ int config_parse_many( const void *table, ConfigParseFlags flags, void *userdata, - Hashmap **ret_stats_by_path) { + Hashmap **ret_stats_by_path, + char ***ret_dropin_files) { _cleanup_strv_free_ char **files = NULL; int r; @@ -602,7 +603,14 @@ int config_parse_many( if (r < 0) return r; - return config_parse_many_files(conf_files, files, sections, lookup, table, flags, userdata, ret_stats_by_path); + r = config_parse_many_files(conf_files, files, sections, lookup, table, flags, userdata, ret_stats_by_path); + if (r < 0) + return r; + + if (ret_dropin_files) + *ret_dropin_files = TAKE_PTR(files); + + return 0; } static int dropins_get_stats_by_path( |