On Tue, Apr 11, 2017 at 05:53:50PM +0200, Peter Krempa wrote:
Similarly to virshDomainFree add a wrapper for the snapshot object freeing function. --- tools/virsh-snapshot.c | 48 ++++++++++++++++++------------------------------ tools/virsh-util.c | 10 ++++++++++ tools/virsh-util.h | 3 +++ 3 files changed, 31 insertions(+), 30 deletions(-)
diff --git a/tools/virsh-util.c b/tools/virsh-util.c index 5fdb40855..e225d3332 100644 --- a/tools/virsh-util.c +++ b/tools/virsh-util.c @@ -160,3 +160,13 @@ virshDomainFree(virDomainPtr dom) virDomainFree(dom); /* sc_prohibit_obj_free_apis_in_virsh */ } + + +void +virshDomainSnapshotFree(virDomainSnapshotPtr snap) +{ + if (!snap) + return; + + virDomainSnapshotFree(snap); /* sc_prohibit_obj_free_apis_in_virsh */ +}
This adds an exemption from the syntax-check without actually enhancing the check. ACK if you tweak the regex in sc_prohibit_obj_free_apis_in_virsh Jan
Attachment:
signature.asc
Description: Digital signature
-- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list