[PATCH 30/46] util: mac: use #pragma once in headers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Jonathon Jongsma <jjongsma@xxxxxxxxxx>
---
 src/util/virmacaddr.h | 17 +++++++----------
 src/util/virmacmap.h  |  5 +----
 2 files changed, 8 insertions(+), 14 deletions(-)

diff --git a/src/util/virmacaddr.h b/src/util/virmacaddr.h
index 55f9d61abe..55cfd12164 100644
--- a/src/util/virmacaddr.h
+++ b/src/util/virmacaddr.h
@@ -18,16 +18,15 @@
  * <http://www.gnu.org/licenses/>.
  */
 
-#ifndef LIBVIRT_VIRMACADDR_H
-# define LIBVIRT_VIRMACADDR_H
+#pragma once
 
-# include "internal.h"
-# include "virautoclean.h"
+#include "internal.h"
+#include "virautoclean.h"
 
-# define VIR_MAC_BUFLEN 6
-# define VIR_MAC_HEXLEN (VIR_MAC_BUFLEN * 2)
-# define VIR_MAC_PREFIX_BUFLEN 3
-# define VIR_MAC_STRING_BUFLEN (VIR_MAC_BUFLEN * 3)
+#define VIR_MAC_BUFLEN 6
+#define VIR_MAC_HEXLEN (VIR_MAC_BUFLEN * 2)
+#define VIR_MAC_PREFIX_BUFLEN 3
+#define VIR_MAC_STRING_BUFLEN (VIR_MAC_BUFLEN * 3)
 
 typedef struct _virMacAddr virMacAddr;
 typedef virMacAddr *virMacAddrPtr;
@@ -65,5 +64,3 @@ bool virMacAddrIsBroadcastRaw(const unsigned char s[VIR_MAC_BUFLEN]);
 void virMacAddrFree(virMacAddrPtr addr);
 
 VIR_DEFINE_AUTOPTR_FUNC(virMacAddr, virMacAddrFree);
-
-#endif /* LIBVIRT_VIRMACADDR_H */
diff --git a/src/util/virmacmap.h b/src/util/virmacmap.h
index 68843b947a..4652295033 100644
--- a/src/util/virmacmap.h
+++ b/src/util/virmacmap.h
@@ -18,8 +18,7 @@
  * <http://www.gnu.org/licenses/>.
  */
 
-#ifndef LIBVIRT_VIRMACMAP_H
-# define LIBVIRT_VIRMACMAP_H
+#pragma once
 
 typedef struct virMacMap virMacMap;
 typedef virMacMap *virMacMapPtr;
@@ -46,5 +45,3 @@ int virMacMapWriteFile(virMacMapPtr mgr,
 
 int virMacMapDumpStr(virMacMapPtr mgr,
                      char **str);
-
-#endif /* LIBVIRT_VIRMACMAP_H */
-- 
2.20.1

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



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux