X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=src%2Fconf-parser.c;h=d18b2a150daafeba8bb5259f45d8700a38ee9a01;hp=1cabc0d789b2d9ef17f9689490e81fb498f2e006;hb=b56e57470c92f123044ea690b5404bdd730ddaa6;hpb=f60f22dfbb8cfa0eb55d1896db0e4c3f7d3cfacb diff --git a/src/conf-parser.c b/src/conf-parser.c index 1cabc0d78..d18b2a150 100644 --- a/src/conf-parser.c +++ b/src/conf-parser.c @@ -1,4 +1,4 @@ -/*-*- Mode: C; c-basic-offset: 8 -*-*/ +/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/ /*** This file is part of systemd. @@ -31,8 +31,6 @@ #include "strv.h" #include "log.h" -#define COMMENTS "#;\n" - /* Run the user supplied parser for an assignment */ static int next_assignment( const char *filename, @@ -122,7 +120,7 @@ static int parse_line(const char *filename, unsigned line, char **section, const return 0; } - if (sections && !strv_contains((char**) sections, *section)) + if (sections && (!*section || !strv_contains((char**) sections, *section))) return 0; if (!(e = strchr(l, '='))) {