]> git.ipfire.org Git - thirdparty/libvirt.git/commit
remove unnecessary cleanup labels and unused return variables
authorLaine Stump <laine@redhat.com>
Tue, 27 Oct 2020 21:49:11 +0000 (17:49 -0400)
committerLaine Stump <laine@redhat.com>
Tue, 3 Nov 2020 03:01:36 +0000 (22:01 -0500)
commit85c8c29214ffcfae50a05d0379afca27a28a147f
treee2277b645fba5763eaadb64c84bc1e2a81089044
parent77401d549c52ba2b11c2132a8ca41d73a4130c85
remove unnecessary cleanup labels and unused return variables

After converting all DIR* to g_autoptr(DIR), many cleanup: labels
ended up just having "return ret", and every place that set ret would
just immediately goto cleanup. Remove the cleanup label and its
return, and just return the set value immediately, thus eliminating
the need for the return variable itself.

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
15 files changed:
src/conf/virnetworkobj.c
src/qemu/qemu_interop_config.c
src/storage/storage_util.c
src/util/vircgroup.c
src/util/vircommand.c
src/util/virdevmapper.c
src/util/virfile.c
src/util/virnetdev.c
src/util/virnuma.c
src/util/virpci.c
src/util/virresctrl.c
src/util/virscsi.c
src/util/virutil.c
src/util/virvhba.c
tests/testutilsqemu.c