rc-update: fix mismatched alloc
Found by GCC 11's -fanalyzer. Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
parent
17496f3c2b
commit
d0a2e30137
@ -288,7 +288,7 @@ int main(int argc, char **argv)
|
|||||||
if (service)
|
if (service)
|
||||||
rc_stringlist_add(runlevels, service);
|
rc_stringlist_add(runlevels, service);
|
||||||
if (!TAILQ_FIRST(runlevels)) {
|
if (!TAILQ_FIRST(runlevels)) {
|
||||||
free(runlevels);
|
rc_stringlist_free(runlevels);
|
||||||
runlevels = rc_runlevel_list();
|
runlevels = rc_runlevel_list();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user