]> xenbits.xensource.com Git - libvirt.git/commitdiff
util: storage: use #pragma once in headers
authorJonathon Jongsma <jjongsma@redhat.com>
Tue, 18 Jun 2019 16:12:47 +0000 (11:12 -0500)
committerJán Tomko <jtomko@redhat.com>
Wed, 19 Jun 2019 15:12:31 +0000 (17:12 +0200)
Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
src/util/virstorageencryption.h
src/util/virstoragefile.h
src/util/virstoragefilebackend.h

index 68d879a63e7be170c5f96c2c71dcc901ea3c0868..3e5485d88bb8dd4cbb903282785bdcb15fff7f2e 100644 (file)
  * <http://www.gnu.org/licenses/>.
  */
 
-#ifndef LIBVIRT_VIRSTORAGEENCRYPTION_H
-# define LIBVIRT_VIRSTORAGEENCRYPTION_H
+#pragma once
 
-# include "internal.h"
-# include "virbuffer.h"
-# include "virsecret.h"
-# include "virutil.h"
-# include "virenum.h"
+#include "internal.h"
+#include "virbuffer.h"
+#include "virsecret.h"
+#include "virutil.h"
+#include "virenum.h"
 
-# include <libxml/tree.h>
+#include <libxml/tree.h>
 
 typedef enum {
     VIR_STORAGE_ENCRYPTION_SECRET_TYPE_PASSPHRASE = 0,
@@ -93,5 +92,3 @@ enum {
 };
 
 int virStorageGenerateQcowPassphrase(unsigned char *dest);
-
-#endif /* LIBVIRT_VIRSTORAGEENCRYPTION_H */
index 763030eefa0ce075737fda91df46ab90e6be7861..38ba9018589f1d0bbdb8db1dbf756818db85cba7 100644 (file)
  * <http://www.gnu.org/licenses/>.
  */
 
-#ifndef LIBVIRT_VIRSTORAGEFILE_H
-# define LIBVIRT_VIRSTORAGEFILE_H
+#pragma once
 
-# include <sys/stat.h>
+#include <sys/stat.h>
 
-# include "virbitmap.h"
-# include "virobject.h"
-# include "virseclabel.h"
-# include "virstorageencryption.h"
-# include "virutil.h"
-# include "virsecret.h"
-# include "virautoclean.h"
-# include "virenum.h"
+#include "virbitmap.h"
+#include "virobject.h"
+#include "virseclabel.h"
+#include "virstorageencryption.h"
+#include "virutil.h"
+#include "virsecret.h"
+#include "virautoclean.h"
+#include "virenum.h"
 
 /* Minimum header size required to probe all known formats with
  * virStorageFileProbeFormat, or obtain metadata from a known format.
@@ -39,7 +38,7 @@
  * 32769).  Some formats can be probed with fewer bytes.  Although
  * some formats theoretically permit metadata that can rely on offsets
  * beyond this size, in practice that doesn't matter.  */
-# define VIR_STORAGE_MAX_HEADER 0x8200
+#define VIR_STORAGE_MAX_HEADER 0x8200
 
 
 /* Types of disk backends (host resource).  Comparable to the public
@@ -341,9 +340,9 @@ struct _virStorageSource {
 };
 
 
-# ifndef DEV_BSIZE
-#  define DEV_BSIZE 512
-# endif
+#ifndef DEV_BSIZE
+# define DEV_BSIZE 512
+#endif
 
 int virStorageFileProbeFormat(const char *path, uid_t uid, gid_t gid);
 
@@ -548,5 +547,3 @@ void virStorageFileReportBrokenChain(int errcode,
                                      virStorageSourcePtr parent);
 
 VIR_DEFINE_AUTOPTR_FUNC(virStorageAuthDef, virStorageAuthDefFree);
-
-#endif /* LIBVIRT_VIRSTORAGEFILE_H */
index c93bc4033a07fed004cb19b032a137264dbfea4c..c7af77bf8f051842de819f299c105927cb65d285 100644 (file)
  * <http://www.gnu.org/licenses/>.
  */
 
-#ifndef LIBVIRT_VIRSTORAGEFILEBACKEND_H
-# define LIBVIRT_VIRSTORAGEFILEBACKEND_H
+#pragma once
 
-# include <sys/stat.h>
+#include <sys/stat.h>
 
-# include "virstoragefile.h"
+#include "virstoragefile.h"
 
 /* ------- virStorageFile backends ------------ */
 typedef struct _virStorageFileBackend virStorageFileBackend;
@@ -99,5 +98,3 @@ struct _virStorageFileBackend {
 };
 
 int virStorageFileBackendRegister(virStorageFileBackendPtr backend);
-
-#endif /* LIBVIRT_VIRSTORAGEFILEBACKEND_H */