lib: properly separate perfdata from different sub subchecks (#2197)
Some checks failed
CodeQL / Analyze (push) Has been cancelled
Spellcheck / codespell (push) Has been cancelled
Tests / Running unit and integrationt tests (push) Has been cancelled
Tests / Running rpm build test on almalinux:9 (push) Has been cancelled
Tests / Running rpm build test on fedora:latest (push) Has been cancelled
Tests / Running rpm build test on rockylinux:8 (push) Has been cancelled
Tests Debian:Testing and Fedora:Rawhide / Running unit and integrationt tests (push) Has been cancelled
Tests Debian:Testing and Fedora:Rawhide / Running rpm build test on fedora:rawhide (push) Has been cancelled

Previously there was a space missing between perfdata from differen sub subchecks which irritated my monitoring system and caused it to interpet two data points as one.
This puts the space back in there.
This commit is contained in:
Lorenz Kästle 2025-12-04 15:31:22 +01:00 committed by GitHub
parent 3ae751ed67
commit 7ab5b3ba34
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -42,7 +42,7 @@ static inline char *fmt_subcheck_perfdata(mp_subcheck check) {
while (subchecks != NULL) {
if (added > 0) {
added = asprintf(&result, "%s%s", result, fmt_subcheck_perfdata(subchecks->subcheck));
added = asprintf(&result, "%s %s", result, fmt_subcheck_perfdata(subchecks->subcheck));
} else {
// TODO free previous result here?
added = asprintf(&result, "%s", fmt_subcheck_perfdata(subchecks->subcheck));