]> git.ipfire.org Git - thirdparty/libvirt.git/commit
util: scsivhost: use VIR_AUTOPTR for aggregate types
authorSukrit Bhatnagar <skrtbhtngr@gmail.com>
Tue, 24 Jul 2018 15:52:31 +0000 (21:22 +0530)
committerErik Skultety <eskultet@redhat.com>
Fri, 27 Jul 2018 15:21:25 +0000 (17:21 +0200)
commit79aea95b2a4b43bf5aef8f950adacf0c81e43746
treea1e24cc186ea61505701e271eefa774a689782b5
parentcef6a2570cd5a77a94308f1f55872fa92961b4c2
util: scsivhost: use VIR_AUTOPTR for aggregate types

By making use of GNU C's cleanup attribute handled by the
VIR_AUTOPTR macro for declaring aggregate pointer variables,
majority of the calls to *Free functions can be dropped, which
in turn leads to getting rid of most of our cleanup sections.

Signed-off-by: Sukrit Bhatnagar <skrtbhtngr@gmail.com>
Reviewed-by: Erik Skultety <eskultet@redhat.com>
src/util/virscsivhost.c