]> git.ipfire.org Git - thirdparty/libvirt.git/commit
util: fcp: use VIR_AUTOFREE instead of VIR_FREE for scalar types
authorSukrit Bhatnagar <skrtbhtngr@gmail.com>
Fri, 13 Jul 2018 17:55:06 +0000 (23:25 +0530)
committerErik Skultety <eskultet@redhat.com>
Sat, 14 Jul 2018 15:01:30 +0000 (17:01 +0200)
commit10f888e64e52adf170c9e83b4c39e6907d840080
treef8f408faa6e8f9a1be9d1f248b8a611e589ea134
parentb204fbc47e74e4ab5e77595c318250aae685a701
util: fcp: use VIR_AUTOFREE instead of VIR_FREE for scalar types

By making use of GNU C's cleanup attribute handled by the
VIR_AUTOFREE macro for declaring scalar variables, majority
of the VIR_FREE calls 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/virfcp.c