summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Sowden <jeremy@azazel.net>2022-12-03 19:02:09 +0000
committerPablo Neira Ayuso <pablo@netfilter.org>2022-12-08 21:48:51 +0100
commit28e6eacfa96f729fce69f003ae16b96ad8503404 (patch)
tree489da7d51ac5a52a09ea4b485ec02310448b7df5
parentcdef3764ad42e7a2daa6d2faa393c9946762d388 (diff)
ulogd: fix parse-error check
If `config_parse_file` returns `-ERRTOOLONG`, `config_errce` may be `NULL`. However, the calling function checks whether `config_errce->key` is `NULL` instead. Signed-off-by: Jeremy Sowden <jeremy@azazel.net> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
-rw-r--r--src/ulogd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ulogd.c b/src/ulogd.c
index b02f260..8ea9793 100644
--- a/src/ulogd.c
+++ b/src/ulogd.c
@@ -1134,7 +1134,7 @@ static int parse_conffile(const char *section, struct config_keyset *ce)
"section \"%s\" not found\n", section);
break;
case -ERRTOOLONG:
- if (config_errce->key)
+ if (config_errce)
ulogd_log(ULOGD_ERROR,
"string value too long for key \"%s\"\n",
config_errce->key);