summaryrefslogtreecommitdiff
path: root/src/shared/conf-parser.h
diff options
context:
space:
mode:
authorJosh Triplett <josh@joshtriplett.org>2014-10-29 05:10:48 -0700
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2014-11-26 19:11:37 -0500
commite8461023531de98ac6a49eff9d6ffeff6315249c (patch)
tree99230bec08ffa8c0c60a1c3c018833793b41140f /src/shared/conf-parser.h
parent7f0a55d4325f7df91f91b3b818f61f97d78df14a (diff)
logind: Support logind.conf.d directories in the usual search paths
This makes it possible to drop in logind configuration snippets from a package or other configuration management mechanism. Add documentation to the header of /etc/logind.conf pointing the user at /etc/logind.conf.d/*.conf. Introduce a new helper, conf_parse_many, to parse configuration files in a search path.
Diffstat (limited to 'src/shared/conf-parser.h')
-rw-r--r--src/shared/conf-parser.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/shared/conf-parser.h b/src/shared/conf-parser.h
index 62f2a01e5e..69d32711b7 100644
--- a/src/shared/conf-parser.h
+++ b/src/shared/conf-parser.h
@@ -92,6 +92,14 @@ int config_parse(const char *unit,
bool warn,
void *userdata);
+int config_parse_many(const char *conf_file, /* possibly NULL */
+ const char *conf_file_dirs, /* nulstr */
+ const char *sections, /* nulstr */
+ ConfigItemLookup lookup,
+ const void *table,
+ bool relaxed,
+ void *userdata);
+
/* Generic parsers */
int config_parse_int(const char *unit, const char *filename, unsigned line, const char *section, unsigned section_line, const char *lvalue, int ltype, const char *rvalue, void *data, void *userdata);
int config_parse_unsigned(const char *unit, const char *filename, unsigned line, const char *section, unsigned section_line, const char *lvalue, int ltype, const char *rvalue, void *data, void *userdata);