]> git.ipfire.org Git - thirdparty/libvirt.git/commit
util: netdevip: use VIR_AUTOFREE instead of VIR_FREE for scalar types
authorSukrit Bhatnagar <skrtbhtngr@gmail.com>
Sat, 28 Jul 2018 18:01:27 +0000 (23:31 +0530)
committerErik Skultety <eskultet@redhat.com>
Tue, 7 Aug 2018 14:29:55 +0000 (16:29 +0200)
commit8214abd60ed3e21e7ec786d99336bbbd4accdfae
treea0fe291715490cca48b95f0c48a788a9b5929285
parenta7a8b7492891a0c8f96c9d6dc99efec916f24ccd
util: netdevip: 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/virnetdevip.c