rc-status: fix mismatched alloc

Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Sam James 2022-03-29 08:00:08 +01:00 committed by William Hubbs
parent c47b37ea68
commit 17496f3c2b

View File

@ -406,7 +406,7 @@ int main(int argc, char **argv)
TAILQ_FOREACH(l, levels, entries) {
nservices = rc_services_in_runlevel_stacked(l->value);
TAILQ_CONCAT(sservices, nservices, entries);
free(nservices);
rc_stringlist_free(nservices);
}
TAILQ_FOREACH_SAFE(s, services, entries, t) {
state = rc_service_state(s->value);