[libvirt] [PATCH v3 00/11] use GNU C's cleanup attribute in src/util (batch III)

Sukrit Bhatnagar posted 11 patches 5 years, 8 months ago
Failed in applying to current master (apply log)
src/util/viriscsi.c             |  22 +-
src/util/virnetdev.c            | 592 ++++++++++++++++------------------------
src/util/virnetdevbridge.c      |  81 ++----
src/util/virnetdevip.c          | 130 ++++-----
src/util/virnetdevopenvswitch.c |  80 ++----
src/util/virnetlink.c           | 112 ++++----
src/util/virnetlink.h           |   5 +
src/util/virqemu.c              |   1 +
8 files changed, 397 insertions(+), 626 deletions(-)
[libvirt] [PATCH v3 00/11] use GNU C's cleanup attribute in src/util (batch III)
Posted by Sukrit Bhatnagar 5 years, 8 months ago
This third series of patches also modifies a few files in src/util
to use VIR_AUTOFREE and VIR_AUTOPTR for automatic freeing of memory
and get rid of some VIR_FREE macro invocations and *Free function
calls.

This is meant as a follow-up of the v1 series [1] of the same batch,
and contains those patches which were not (completely) pushed upstream.


[1] https://www.redhat.com/archives/libvir-list/2018-July/msg01947.html

Sukrit Bhatnagar (11):
  util: iscsi: use VIR_AUTOFREE instead of VIR_FREE for scalar types
  util: netlink: define cleanup function using VIR_DEFINE_AUTOPTR_FUNC
  util: netlink: use VIR_AUTOFREE instead of VIR_FREE for scalar types
  util: netlink: use VIR_AUTOPTR for aggregate types
  util: netdevbridge: use VIR_AUTOFREE instead of VIR_FREE for scalar
    types
  util: netdevbridge: use VIR_AUTOPTR for aggregate types
  util: netdev: use VIR_AUTOFREE instead of VIR_FREE for scalar types
  util: netdev: use VIR_AUTOPTR for aggregate types
  util: netdevip: use VIR_AUTOPTR for aggregate types
  util: netdevopenvswitch: use VIR_AUTOPTR for aggregate types
  util: qemu: use VIR_AUTOPTR for aggregate types

 src/util/viriscsi.c             |  22 +-
 src/util/virnetdev.c            | 592 ++++++++++++++++------------------------
 src/util/virnetdevbridge.c      |  81 ++----
 src/util/virnetdevip.c          | 130 ++++-----
 src/util/virnetdevopenvswitch.c |  80 ++----
 src/util/virnetlink.c           | 112 ++++----
 src/util/virnetlink.h           |   5 +
 src/util/virqemu.c              |   1 +
 8 files changed, 397 insertions(+), 626 deletions(-)

-- 
1.8.3.1

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH v3 00/11] use GNU C's cleanup attribute in src/util (batch III)
Posted by Erik Skultety 5 years, 8 months ago
On Thu, Aug 09, 2018 at 09:42:08AM +0530, Sukrit Bhatnagar wrote:
> This third series of patches also modifies a few files in src/util
> to use VIR_AUTOFREE and VIR_AUTOPTR for automatic freeing of memory
> and get rid of some VIR_FREE macro invocations and *Free function
> calls.
>
> This is meant as a follow-up of the v1 series [1] of the same batch,
> and contains those patches which were not (completely) pushed upstream.

So I pushed all the patches except for 7 and 8 (technically I could have gone
with 8 too, but there were lots of merge conflicts, so I figured it would be
easier to send it along with 7 again rather than risk a mistake because of a
rebase).

Erik

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list