[libvirt] [PATCH] util: Use a semicolon for all VIR_DEFINE_AUTOPTR_FUNC

John Ferlan posted 1 patch 1 week ago
Test syntax-check passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/20190208115208.9745-1-jferlan@redhat.com
src/qemu/qemu_migration_params.h | 2 +-
src/util/virauthconfig.h         | 2 +-
src/util/virbitmap.h             | 2 +-
src/util/virbuffer.c             | 2 +-
src/util/virbuffer.h             | 2 +-
src/util/vircommand.h            | 2 +-
src/util/virerror.h              | 2 +-
src/util/virfile.h               | 2 +-
src/util/virfirewall.h           | 2 +-
src/util/virhash.h               | 2 +-
src/util/virjson.h               | 2 +-
src/util/virmacaddr.h            | 2 +-
src/util/virmdev.h               | 4 ++--
src/util/virnetdev.c             | 2 +-
src/util/virnetdev.h             | 2 +-
src/util/virnetdevip.h           | 4 ++--
src/util/virnetdevvlan.h         | 2 +-
src/util/virnetlink.c            | 2 +-
src/util/virnetlink.h            | 2 +-
src/util/virpci.h                | 6 +++---
src/util/virperf.h               | 2 +-
src/util/virscsi.c               | 2 +-
src/util/virscsi.h               | 2 +-
src/util/virscsivhost.h          | 2 +-
src/util/virsocketaddr.h         | 2 +-
src/util/virstring.h             | 2 +-
src/util/virusb.h                | 2 +-
27 files changed, 31 insertions(+), 31 deletions(-)

[libvirt] [PATCH] util: Use a semicolon for all VIR_DEFINE_AUTOPTR_FUNC

Posted by John Ferlan 1 week ago
For consistency, let's use the semicolon for all definitions.

Signed-off-by: John Ferlan <jferlan@redhat.com>
---

 As discussed in the other series - 

 src/qemu/qemu_migration_params.h | 2 +-
 src/util/virauthconfig.h         | 2 +-
 src/util/virbitmap.h             | 2 +-
 src/util/virbuffer.c             | 2 +-
 src/util/virbuffer.h             | 2 +-
 src/util/vircommand.h            | 2 +-
 src/util/virerror.h              | 2 +-
 src/util/virfile.h               | 2 +-
 src/util/virfirewall.h           | 2 +-
 src/util/virhash.h               | 2 +-
 src/util/virjson.h               | 2 +-
 src/util/virmacaddr.h            | 2 +-
 src/util/virmdev.h               | 4 ++--
 src/util/virnetdev.c             | 2 +-
 src/util/virnetdev.h             | 2 +-
 src/util/virnetdevip.h           | 4 ++--
 src/util/virnetdevvlan.h         | 2 +-
 src/util/virnetlink.c            | 2 +-
 src/util/virnetlink.h            | 2 +-
 src/util/virpci.h                | 6 +++---
 src/util/virperf.h               | 2 +-
 src/util/virscsi.c               | 2 +-
 src/util/virscsi.h               | 2 +-
 src/util/virscsivhost.h          | 2 +-
 src/util/virsocketaddr.h         | 2 +-
 src/util/virstring.h             | 2 +-
 src/util/virusb.h                | 2 +-
 27 files changed, 31 insertions(+), 31 deletions(-)

diff --git a/src/qemu/qemu_migration_params.h b/src/qemu/qemu_migration_params.h
index 2460684a00..233ebe772b 100644
--- a/src/qemu/qemu_migration_params.h
+++ b/src/qemu/qemu_migration_params.h
@@ -90,7 +90,7 @@ qemuMigrationParamsNew(void);
 
 void
 qemuMigrationParamsFree(qemuMigrationParamsPtr migParams);
-VIR_DEFINE_AUTOPTR_FUNC(qemuMigrationParams, qemuMigrationParamsFree)
+VIR_DEFINE_AUTOPTR_FUNC(qemuMigrationParams, qemuMigrationParamsFree);
 
 int
 qemuMigrationParamsApply(virQEMUDriverPtr driver,
diff --git a/src/util/virauthconfig.h b/src/util/virauthconfig.h
index 93bb434616..603ef89d25 100644
--- a/src/util/virauthconfig.h
+++ b/src/util/virauthconfig.h
@@ -41,6 +41,6 @@ int virAuthConfigLookup(virAuthConfigPtr auth,
                         const char *credname,
                         const char **value);
 
-VIR_DEFINE_AUTOPTR_FUNC(virAuthConfig, virAuthConfigFree)
+VIR_DEFINE_AUTOPTR_FUNC(virAuthConfig, virAuthConfigFree);
 
 #endif /* LIBVIRT_VIRAUTHCONFIG_H */
diff --git a/src/util/virbitmap.h b/src/util/virbitmap.h
index dfb30b3bc8..c54e203971 100644
--- a/src/util/virbitmap.h
+++ b/src/util/virbitmap.h
@@ -154,6 +154,6 @@ void virBitmapSubtract(virBitmapPtr a, virBitmapPtr b)
 
 void virBitmapShrink(virBitmapPtr map, size_t b);
 
-VIR_DEFINE_AUTOPTR_FUNC(virBitmap, virBitmapFree)
+VIR_DEFINE_AUTOPTR_FUNC(virBitmap, virBitmapFree);
 
 #endif /* LIBVIRT_VIRBITMAP_H */
diff --git a/src/util/virbuffer.c b/src/util/virbuffer.c
index 95c0dd1b96..01d71f1b59 100644
--- a/src/util/virbuffer.c
+++ b/src/util/virbuffer.c
@@ -661,7 +661,7 @@ virBufferEscapePairFree(virBufferEscapePairPtr pair)
     VIR_FREE(pair);
 }
 
-VIR_DEFINE_AUTOPTR_FUNC(virBufferEscapePair, virBufferEscapePairFree)
+VIR_DEFINE_AUTOPTR_FUNC(virBufferEscapePair, virBufferEscapePairFree);
 
 
 /**
diff --git a/src/util/virbuffer.h b/src/util/virbuffer.h
index c3703710b7..8bf6bee644 100644
--- a/src/util/virbuffer.h
+++ b/src/util/virbuffer.h
@@ -119,6 +119,6 @@ int virBufferGetIndent(const virBuffer *buf, bool dynamic);
 void virBufferTrim(virBufferPtr buf, const char *trim, int len);
 void virBufferAddStr(virBufferPtr buf, const char *str);
 
-VIR_DEFINE_AUTOPTR_FUNC(virBuffer, virBufferFreeAndReset)
+VIR_DEFINE_AUTOPTR_FUNC(virBuffer, virBufferFreeAndReset);
 
 #endif /* LIBVIRT_VIRBUFFER_H */
diff --git a/src/util/vircommand.h b/src/util/vircommand.h
index dbf5041890..99849051f8 100644
--- a/src/util/vircommand.h
+++ b/src/util/vircommand.h
@@ -219,6 +219,6 @@ int virCommandRunNul(virCommandPtr cmd,
                      virCommandRunNulFunc func,
                      void *data);
 
-VIR_DEFINE_AUTOPTR_FUNC(virCommand, virCommandFree)
+VIR_DEFINE_AUTOPTR_FUNC(virCommand, virCommandFree);
 
 #endif /* LIBVIRT_VIRCOMMAND_H */
diff --git a/src/util/virerror.h b/src/util/virerror.h
index d9d3109a4c..213bc3f606 100644
--- a/src/util/virerror.h
+++ b/src/util/virerror.h
@@ -206,6 +206,6 @@ bool virLastErrorIsSystemErrno(int errnum);
 void virErrorPreserveLast(virErrorPtr *saveerr);
 void virErrorRestore(virErrorPtr *savederr);
 
-VIR_DEFINE_AUTOPTR_FUNC(virError, virFreeError)
+VIR_DEFINE_AUTOPTR_FUNC(virError, virFreeError);
 
 #endif /* LIBVIRT_VIRERROR_H */
diff --git a/src/util/virfile.h b/src/util/virfile.h
index 65432da13a..be612af770 100644
--- a/src/util/virfile.h
+++ b/src/util/virfile.h
@@ -383,7 +383,7 @@ int virFileInData(int fd,
                   int *inData,
                   long long *length);
 
-VIR_DEFINE_AUTOPTR_FUNC(virFileWrapperFd, virFileWrapperFdFree)
+VIR_DEFINE_AUTOPTR_FUNC(virFileWrapperFd, virFileWrapperFdFree);
 
 int virFileGetXAttr(const char *path,
                     const char *name,
diff --git a/src/util/virfirewall.h b/src/util/virfirewall.h
index 2a6fc30eb7..e3ad1adb6b 100644
--- a/src/util/virfirewall.h
+++ b/src/util/virfirewall.h
@@ -115,6 +115,6 @@ int virFirewallApply(virFirewallPtr firewall);
 
 void virFirewallSetLockOverride(bool avoid);
 
-VIR_DEFINE_AUTOPTR_FUNC(virFirewall, virFirewallFree)
+VIR_DEFINE_AUTOPTR_FUNC(virFirewall, virFirewallFree);
 
 #endif /* LIBVIRT_VIRFIREWALL_H */
diff --git a/src/util/virhash.h b/src/util/virhash.h
index 0c849561f8..2df1a5d12a 100644
--- a/src/util/virhash.h
+++ b/src/util/virhash.h
@@ -197,6 +197,6 @@ void *virHashSearch(const virHashTable *table, virHashSearcher iter,
 /* Convenience for when VIR_FREE(value) is sufficient as a data freer.  */
 void virHashValueFree(void *value, const void *name);
 
-VIR_DEFINE_AUTOPTR_FUNC(virHashTable, virHashFree)
+VIR_DEFINE_AUTOPTR_FUNC(virHashTable, virHashFree);
 
 #endif /* LIBVIRT_VIRHASH_H */
diff --git a/src/util/virjson.h b/src/util/virjson.h
index d815e60de9..3dee103aba 100644
--- a/src/util/virjson.h
+++ b/src/util/virjson.h
@@ -158,6 +158,6 @@ char *virJSONStringReformat(const char *jsonstr, bool pretty);
 
 virJSONValuePtr virJSONValueObjectDeflatten(virJSONValuePtr json);
 
-VIR_DEFINE_AUTOPTR_FUNC(virJSONValue, virJSONValueFree)
+VIR_DEFINE_AUTOPTR_FUNC(virJSONValue, virJSONValueFree);
 
 #endif /* LIBVIRT_VIRJSON_H */
diff --git a/src/util/virmacaddr.h b/src/util/virmacaddr.h
index 3999de3421..1deaf087e0 100644
--- a/src/util/virmacaddr.h
+++ b/src/util/virmacaddr.h
@@ -64,6 +64,6 @@ bool virMacAddrIsMulticast(const virMacAddr *addr);
 bool virMacAddrIsBroadcastRaw(const unsigned char s[VIR_MAC_BUFLEN]);
 void virMacAddrFree(virMacAddrPtr addr);
 
-VIR_DEFINE_AUTOPTR_FUNC(virMacAddr, virMacAddrFree)
+VIR_DEFINE_AUTOPTR_FUNC(virMacAddr, virMacAddrFree);
 
 #endif /* LIBVIRT_VIRMACADDR_H */
diff --git a/src/util/virmdev.h b/src/util/virmdev.h
index aafc8b9317..d787d354e4 100644
--- a/src/util/virmdev.h
+++ b/src/util/virmdev.h
@@ -137,7 +137,7 @@ int
 virMediatedDeviceTypeReadAttrs(const char *sysfspath,
                                virMediatedDeviceTypePtr *type);
 
-VIR_DEFINE_AUTOPTR_FUNC(virMediatedDevice, virMediatedDeviceFree)
-VIR_DEFINE_AUTOPTR_FUNC(virMediatedDeviceType, virMediatedDeviceTypeFree)
+VIR_DEFINE_AUTOPTR_FUNC(virMediatedDevice, virMediatedDeviceFree);
+VIR_DEFINE_AUTOPTR_FUNC(virMediatedDeviceType, virMediatedDeviceTypeFree);
 
 #endif /* LIBVIRT_VIRMDEV_H */
diff --git a/src/util/virnetdev.c b/src/util/virnetdev.c
index 50947b302b..aeb9caab2a 100644
--- a/src/util/virnetdev.c
+++ b/src/util/virnetdev.c
@@ -121,7 +121,7 @@ virNetDevMcastEntryFree(virNetDevMcastEntryPtr entry)
     VIR_FREE(entry);
 }
 
-VIR_DEFINE_AUTOPTR_FUNC(virNetDevMcastEntry, virNetDevMcastEntryFree)
+VIR_DEFINE_AUTOPTR_FUNC(virNetDevMcastEntry, virNetDevMcastEntryFree);
 
 typedef struct _virNetDevMcastList virNetDevMcastList;
 typedef virNetDevMcastList *virNetDevMcastListPtr;
diff --git a/src/util/virnetdev.h b/src/util/virnetdev.h
index 3982097cdf..6f6094eebe 100644
--- a/src/util/virnetdev.h
+++ b/src/util/virnetdev.h
@@ -311,6 +311,6 @@ int virNetDevSysfsFile(char **pf_sysfs_device_link,
 int virNetDevRunEthernetScript(const char *ifname, const char *script)
     ATTRIBUTE_NOINLINE;
 
-VIR_DEFINE_AUTOPTR_FUNC(virNetDevRxFilter, virNetDevRxFilterFree)
+VIR_DEFINE_AUTOPTR_FUNC(virNetDevRxFilter, virNetDevRxFilterFree);
 
 #endif /* LIBVIRT_VIRNETDEV_H */
diff --git a/src/util/virnetdevip.h b/src/util/virnetdevip.h
index 1ecb4eae01..376ac32c47 100644
--- a/src/util/virnetdevip.h
+++ b/src/util/virnetdevip.h
@@ -94,7 +94,7 @@ void virNetDevIPInfoClear(virNetDevIPInfoPtr ip);
 int virNetDevIPInfoAddToDev(const char *ifname,
                             virNetDevIPInfo const *ipInfo);
 
-VIR_DEFINE_AUTOPTR_FUNC(virNetDevIPAddr, virNetDevIPAddrFree)
-VIR_DEFINE_AUTOPTR_FUNC(virNetDevIPRoute, virNetDevIPRouteFree)
+VIR_DEFINE_AUTOPTR_FUNC(virNetDevIPAddr, virNetDevIPAddrFree);
+VIR_DEFINE_AUTOPTR_FUNC(virNetDevIPRoute, virNetDevIPRouteFree);
 
 #endif /* LIBVIRT_VIRNETDEVIP_H */
diff --git a/src/util/virnetdevvlan.h b/src/util/virnetdevvlan.h
index 8fe3a4dfa7..2a13759550 100644
--- a/src/util/virnetdevvlan.h
+++ b/src/util/virnetdevvlan.h
@@ -48,6 +48,6 @@ void virNetDevVlanFree(virNetDevVlanPtr vlan);
 int virNetDevVlanEqual(const virNetDevVlan *a, const virNetDevVlan *b);
 int virNetDevVlanCopy(virNetDevVlanPtr dst, const virNetDevVlan *src);
 
-VIR_DEFINE_AUTOPTR_FUNC(virNetDevVlan, virNetDevVlanFree)
+VIR_DEFINE_AUTOPTR_FUNC(virNetDevVlan, virNetDevVlanFree);
 
 #endif /* LIBVIRT_VIRNETDEVVLAN_H */
diff --git a/src/util/virnetlink.c b/src/util/virnetlink.c
index 62066a33d2..1d8467e643 100644
--- a/src/util/virnetlink.c
+++ b/src/util/virnetlink.c
@@ -63,7 +63,7 @@ typedef struct nl_handle virNetlinkHandle;
 typedef struct nl_sock virNetlinkHandle;
 # endif
 
-VIR_DEFINE_AUTOPTR_FUNC(virNetlinkHandle, virNetlinkFree)
+VIR_DEFINE_AUTOPTR_FUNC(virNetlinkHandle, virNetlinkFree);
 
 typedef struct _virNetlinkEventSrvPrivate virNetlinkEventSrvPrivate;
 typedef virNetlinkEventSrvPrivate *virNetlinkEventSrvPrivatePtr;
diff --git a/src/util/virnetlink.h b/src/util/virnetlink.h
index 37442be44c..9dd7b3c3ed 100644
--- a/src/util/virnetlink.h
+++ b/src/util/virnetlink.h
@@ -37,7 +37,7 @@
 #  endif
 
 typedef struct nl_msg virNetlinkMsg;
-VIR_DEFINE_AUTOPTR_FUNC(virNetlinkMsg, nlmsg_free)
+VIR_DEFINE_AUTOPTR_FUNC(virNetlinkMsg, nlmsg_free);
 
 # else
 
diff --git a/src/util/virpci.h b/src/util/virpci.h
index 0b35228e3d..c8fc1e8bf6 100644
--- a/src/util/virpci.h
+++ b/src/util/virpci.h
@@ -271,8 +271,8 @@ ssize_t virPCIGetMdevTypes(const char *sysfspath,
 
 void virPCIDeviceAddressFree(virPCIDeviceAddressPtr address);
 
-VIR_DEFINE_AUTOPTR_FUNC(virPCIDevice, virPCIDeviceFree)
-VIR_DEFINE_AUTOPTR_FUNC(virPCIDeviceAddress, virPCIDeviceAddressFree)
-VIR_DEFINE_AUTOPTR_FUNC(virPCIEDeviceInfo, virPCIEDeviceInfoFree)
+VIR_DEFINE_AUTOPTR_FUNC(virPCIDevice, virPCIDeviceFree);
+VIR_DEFINE_AUTOPTR_FUNC(virPCIDeviceAddress, virPCIDeviceAddressFree);
+VIR_DEFINE_AUTOPTR_FUNC(virPCIEDeviceInfo, virPCIEDeviceInfoFree);
 
 #endif /* LIBVIRT_VIRPCI_H */
diff --git a/src/util/virperf.h b/src/util/virperf.h
index 0d026e80c2..3cd26563b4 100644
--- a/src/util/virperf.h
+++ b/src/util/virperf.h
@@ -82,6 +82,6 @@ int virPerfReadEvent(virPerfPtr perf,
                      virPerfEventType type,
                      uint64_t *value);
 
-VIR_DEFINE_AUTOPTR_FUNC(virPerf, virPerfFree)
+VIR_DEFINE_AUTOPTR_FUNC(virPerf, virPerfFree);
 
 #endif /* LIBVIRT_VIRPERF_H */
diff --git a/src/util/virscsi.c b/src/util/virscsi.c
index 715064d669..b27831f0b3 100644
--- a/src/util/virscsi.c
+++ b/src/util/virscsi.c
@@ -248,7 +248,7 @@ virSCSIDeviceUsedByInfoFree(virUsedByInfoPtr used_by)
     VIR_FREE(used_by->domname);
     VIR_FREE(used_by);
 }
-VIR_DEFINE_AUTOPTR_FUNC(virUsedByInfo, virSCSIDeviceUsedByInfoFree)
+VIR_DEFINE_AUTOPTR_FUNC(virUsedByInfo, virSCSIDeviceUsedByInfoFree);
 
 void
 virSCSIDeviceFree(virSCSIDevicePtr dev)
diff --git a/src/util/virscsi.h b/src/util/virscsi.h
index fd5986d2c0..70e113b486 100644
--- a/src/util/virscsi.h
+++ b/src/util/virscsi.h
@@ -93,6 +93,6 @@ void virSCSIDeviceListDel(virSCSIDeviceListPtr list,
 virSCSIDevicePtr virSCSIDeviceListFind(virSCSIDeviceListPtr list,
                                        virSCSIDevicePtr dev);
 
-VIR_DEFINE_AUTOPTR_FUNC(virSCSIDevice, virSCSIDeviceFree)
+VIR_DEFINE_AUTOPTR_FUNC(virSCSIDevice, virSCSIDeviceFree);
 
 #endif /* LIBVIRT_VIRSCSI_H */
diff --git a/src/util/virscsivhost.h b/src/util/virscsivhost.h
index 5440db16b2..d28773482c 100644
--- a/src/util/virscsivhost.h
+++ b/src/util/virscsivhost.h
@@ -61,6 +61,6 @@ void virSCSIVHostDeviceGetUsedBy(virSCSIVHostDevicePtr dev,
 void virSCSIVHostDeviceFree(virSCSIVHostDevicePtr dev);
 int virSCSIVHostOpenVhostSCSI(int *vhostfd) ATTRIBUTE_NOINLINE;
 
-VIR_DEFINE_AUTOPTR_FUNC(virSCSIVHostDevice, virSCSIVHostDeviceFree)
+VIR_DEFINE_AUTOPTR_FUNC(virSCSIVHostDevice, virSCSIVHostDeviceFree);
 
 #endif /* LIBVIRT_VIRSCSIVHOST_H */
diff --git a/src/util/virsocketaddr.h b/src/util/virsocketaddr.h
index 64bcbb36dc..f6caa4fcf5 100644
--- a/src/util/virsocketaddr.h
+++ b/src/util/virsocketaddr.h
@@ -160,6 +160,6 @@ int virSocketAddrPTRDomain(const virSocketAddr *addr,
 
 void virSocketAddrFree(virSocketAddrPtr addr);
 
-VIR_DEFINE_AUTOPTR_FUNC(virSocketAddr, virSocketAddrFree)
+VIR_DEFINE_AUTOPTR_FUNC(virSocketAddr, virSocketAddrFree);
 
 #endif /* LIBVIRT_VIRSOCKETADDR_H */
diff --git a/src/util/virstring.h b/src/util/virstring.h
index 42848e62b1..aef82471c2 100644
--- a/src/util/virstring.h
+++ b/src/util/virstring.h
@@ -307,6 +307,6 @@ int virStringParsePort(const char *str,
                        unsigned int *port)
     ATTRIBUTE_NONNULL(2) ATTRIBUTE_RETURN_CHECK;
 
-VIR_DEFINE_AUTOPTR_FUNC(virString, virStringListFree)
+VIR_DEFINE_AUTOPTR_FUNC(virString, virStringListFree);
 
 #endif /* LIBVIRT_VIRSTRING_H */
diff --git a/src/util/virusb.h b/src/util/virusb.h
index e589a45310..6ed71606d4 100644
--- a/src/util/virusb.h
+++ b/src/util/virusb.h
@@ -96,6 +96,6 @@ void virUSBDeviceListDel(virUSBDeviceListPtr list,
 virUSBDevicePtr virUSBDeviceListFind(virUSBDeviceListPtr list,
                                      virUSBDevicePtr dev);
 
-VIR_DEFINE_AUTOPTR_FUNC(virUSBDevice, virUSBDeviceFree)
+VIR_DEFINE_AUTOPTR_FUNC(virUSBDevice, virUSBDeviceFree);
 
 #endif /* LIBVIRT_VIRUSB_H */
-- 
2.20.1

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

Re: [libvirt] [PATCH] util: Use a semicolon for all VIR_DEFINE_AUTOPTR_FUNC

Posted by Erik Skultety 1 week ago
On Fri, Feb 08, 2019 at 06:52:08AM -0500, John Ferlan wrote:
> For consistency, let's use the semicolon for all definitions.
>
> Signed-off-by: John Ferlan <jferlan@redhat.com>
> ---
>
>  As discussed in the other series -

Reviewed-by: Erik Skultety <eskultet@redhat.com>

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