db/update/ExcludeList: allow comments only at start of line

This commit is contained in:
Max Kellermann
2018-07-06 18:27:17 +02:00
parent d5c132fca0
commit 63406efcd8
2 changed files with 3 additions and 6 deletions

View File

@@ -38,12 +38,8 @@
inline void
ExcludeList::ParseLine(char *line) noexcept
{
char *p = strchr(line, '#');
if (p != nullptr)
*p = 0;
p = Strip(line);
if (*p != 0)
char *p = Strip(line);
if (*p != 0 && *p != '#')
patterns.emplace_front(p);
}