[libvirt] [PATCH 2/5] util: Move the VIR_AUTO(CLEAN|PTR) helper macros into a separate header

Ján Tomko jtomko at redhat.com
Mon Apr 8 08:28:57 UTC 2019


On Wed, Apr 03, 2019 at 03:06:34PM +0200, Peter Krempa wrote:
>Keeping them with viralloc.h forcibly pulls in the other stuff from
>viralloc.h into other header files. This in turn creates a mess
>as more and more headers pull in the 'viral' header file.
>
>If we want to make 'viralloc.h' omnipresent we should pick a different
>approach.
>
>Signed-off-by: Peter Krempa <pkrempa at redhat.com>
>---
> src/Makefile.am          |  2 +
> src/util/Makefile.inc.am |  1 +
> src/util/viralloc.h      | 66 -----------------------------
> src/util/virauthconfig.h |  1 +
> src/util/virautoclean.h  | 90 ++++++++++++++++++++++++++++++++++++++++
> src/util/virbitmap.h     |  1 +
> src/util/virbuffer.h     |  1 +
> src/util/virerror.h      |  1 +
> src/util/virfirewall.h   |  1 +
> src/util/virhash.h       |  1 +
> src/util/virmacaddr.h    |  1 +
> src/util/virnetdevvlan.h |  1 +
> src/util/virperf.h       |  1 +
> src/util/virsocketaddr.h |  1 +
> 14 files changed, 103 insertions(+), 66 deletions(-)
> create mode 100644 src/util/virautoclean.h
>

The following files seem to be using VIR_AUTO macros without an explicit
#include of virautoclean.h:

src/conf/domain_capabilities.h
src/conf/storage_conf.h
src/qemu/qemu_firmware.h
src/qemu/qemu_migration_params.h
src/util/vircommand.h
src/util/virfile.h
src/util/virjson.h
src/util/virmdev.h
src/util/virnetdev.h
src/util/virnetdevip.h
src/util/virnetlink.h
src/util/virpci.h
src/util/virscsi.h
src/util/virscsivhost.h
src/util/virsocketaddr.h
src/util/virstoragefile.h
src/util/virusb.h
src/util/virxml.h

With that fixed:
Reviewed-by: Ján Tomko <jtomko at redhat.com>

Jano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20190408/177b915d/attachment-0001.sig>


More information about the libvir-list mailing list