summaryrefslogtreecommitdiffstats
path: root/collectors/plugins.d
diff options
context:
space:
mode:
authorIlya Mashchenko <ilya@netdata.cloud>2023-10-03 18:10:13 +0300
committerGitHub <noreply@github.com>2023-10-03 18:10:13 +0300
commit3baedcc1e9984bd494245271330322fa73d37f34 (patch)
treef9f5eb823906f89a630159d4d12f20707d8a0dd7 /collectors/plugins.d
parent3aa9ce6e5034329af7b7e944581bfa51f47c4bfa (diff)
fix crash on parsing clabel command with no source (#16114)
fix parsing clabel command with no source
Diffstat (limited to 'collectors/plugins.d')
-rw-r--r--collectors/plugins.d/pluginsd_parser.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/collectors/plugins.d/pluginsd_parser.c b/collectors/plugins.d/pluginsd_parser.c
index 126db7f2a4..12b92749bd 100644
--- a/collectors/plugins.d/pluginsd_parser.c
+++ b/collectors/plugins.d/pluginsd_parser.c
@@ -1277,7 +1277,7 @@ static inline PARSER_RC pluginsd_clabel(char **words, size_t num_words, PARSER *
const char *value = get_word(words, num_words, 2);
const char *label_source = get_word(words, num_words, 3);
- if (!name || !value || !*label_source) {
+ if (!name || !value || !label_source) {
netdata_log_error("Ignoring malformed or empty CHART LABEL command.");
return PLUGINSD_DISABLE_PLUGIN(parser, NULL, NULL);
}