[PATCH 10/25] network: convert local pointers to g_auto*

Ján Tomko jtomko at redhat.com
Thu Jun 25 23:31:27 UTC 2020


On a Wednesday in 2020, Laine Stump wrote:
>This includes those that use plain VIR_FREE() as well as those that
>have a cleanup function defined for use via g_auto/g_autoptr
>(virCommand, virFirewall, virBuffer, virJSONValue etc).
>
>Signed-off-by: Laine Stump <laine at redhat.com>
>---
> src/network/bridge_driver.c       | 477 +++++++++++-------------------
> src/network/bridge_driver_linux.c |  55 ++--
> src/network/leaseshelper.c        |  16 +-
> src/util/virdnsmasq.h             |   4 +
> 4 files changed, 209 insertions(+), 343 deletions(-)
>

Since this patch touches way too many functions, it would be much easier
to read in two separate commits:
1) add g_auto markers and remove the corresponding VIR_FREE's, possibly
    leaving empty cleanup sections
2) removing all the now unnecessary labels and gotos

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/20200626/89810a23/attachment-0001.sig>


More information about the libvir-list mailing list