diff --git a/src/cmt_decode_statsd.c b/src/cmt_decode_statsd.c index 835ef40..7d92948 100644 --- a/src/cmt_decode_statsd.c +++ b/src/cmt_decode_statsd.c @@ -138,6 +138,9 @@ static int decode_labels(struct cmt *cmt, while (label_kv != NULL) { colon = strchr(label_kv, ':'); + if (colon == NULL) { + break; + } label_k = cfl_sds_create_len(label_kv, colon - label_kv); if (label_k == NULL) { free(value_index_list);