From b8e7a47baf10683f59bf848abd300b45cd5042f2 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Fri, 21 Feb 2014 18:57:15 +0100 Subject: man: don't document ".include" in configuration files anymore as first step to deprecate them one day --- src/shared/conf-parser.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src') diff --git a/src/shared/conf-parser.c b/src/shared/conf-parser.c index d5a639e874..dde62b5755 100644 --- a/src/shared/conf-parser.c +++ b/src/shared/conf-parser.c @@ -225,6 +225,15 @@ static int parse_line(const char* unit, if (startswith(l, ".include ")) { _cleanup_free_ char *fn = NULL; + /* .includes are a bad idea, we only support them here + * for historical reasons. They create cyclic include + * problems and make it difficult to detect + * configuration file changes with an easy + * stat(). Better approaches, such as .d/ drop-in + * snippets exist. + * + * Support for them should be eventually removed. */ + if (!allow_include) { log_syntax(unit, LOG_ERR, filename, line, EBADMSG, ".include not allowed here. Ignoring."); -- cgit v1.2.3-54-g00ecf