]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Fixup the headers formatting
authorOndřej Surý <ondrej@isc.org>
Wed, 11 Mar 2020 09:19:32 +0000 (10:19 +0100)
committerOndřej Surý <ondrej@isc.org>
Wed, 11 Mar 2020 09:19:32 +0000 (10:19 +0100)
17 files changed:
bin/named/win32/include/named/ntservice.h
contrib/dlz/drivers/include/dlz/sdlz_helper.h
contrib/dlz/modules/include/dlz_dbi.h
contrib/dlz/modules/include/dlz_minimal.h
lib/irs/win32/include/irs/netdb.h
lib/isc/pthreads/include/isc/mutex.h
lib/isc/pthreads/include/isc/thread.h
lib/isc/unix/include/isc/dir.h
lib/isc/unix/include/isc/net.h
lib/isc/unix/include/isc/offset.h
lib/isc/unix/include/isc/stdatomic.h
lib/isc/win32/include/isc/condition.h
lib/isc/win32/include/isc/dir.h
lib/isc/win32/include/isc/net.h
lib/isc/win32/include/isc/offset.h
lib/isc/win32/include/isc/stdatomic.h
lib/isc/win32/include/isc/thread.h

index 05f4f7c65f759df66b2767cc8568f126596011b7..8fe6f5b32eeaa39614c4dfb72a67be662f0ad737 100644 (file)
@@ -18,7 +18,7 @@
 #define BIND_SERVICE_NAME "named"
 
 void
-ntservice_init();
+     ntservice_init();
 void UpdateSCM(DWORD);
 void
 ServiceControl(DWORD dwCtrlCode);
index 55ac8c70f03a1a6434f2acdb2e055122f34053db..d46db7c21ad097e05b3f6c946635423db92dc16d 100644 (file)
@@ -57,9 +57,9 @@ typedef struct driverinstance driverinstance_t;
  * special tokens are %zone%, %record%, %client%
  */
 struct query_segment {
-       void *sql;
+       void *       sql;
        unsigned int strlen;
-       bool direct;
+       bool         direct;
        ISC_LINK(query_segment_t) link;
 };
 
@@ -71,19 +71,19 @@ struct query_segment {
  * make sure no two threads try to use the same DBI at a time.
  */
 struct dbinstance {
-       void *dbconn;
+       void *        dbconn;
        query_list_t *allnodes_q;
        query_list_t *allowxfr_q;
        query_list_t *authority_q;
        query_list_t *findzone_q;
        query_list_t *lookup_q;
        query_list_t *countzone_q;
-       char *query_buf;
-       char *zone;
-       char *record;
-       char *client;
-       isc_mem_t *mctx;
-       isc_mutex_t instance_lock;
+       char *        query_buf;
+       char *        zone;
+       char *        record;
+       char *        client;
+       isc_mem_t *   mctx;
+       isc_mutex_t   instance_lock;
        ISC_LINK(dbinstance_t) link;
 };
 
index 12952b923fbf0451abd51585671a31574bc8a9fe..735359c8731893df59e0b54fa0385dde6fa08abd 100644 (file)
@@ -61,9 +61,9 @@ typedef struct driverinstance driverinstance_t;
  * special tokens are %zone%, %record%, %client%
  */
 struct query_segment {
-       void *cmd;
+       void *       cmd;
        unsigned int strlen;
-       bool direct;
+       bool         direct;
        DLZ_LINK(query_segment_t) link;
 };
 
@@ -75,18 +75,18 @@ struct query_segment {
  * make sure no two threads try to use the same DBI at a time.
  */
 struct dbinstance {
-       void *dbconn;
+       void *        dbconn;
        query_list_t *allnodes_q;
        query_list_t *allowxfr_q;
        query_list_t *authority_q;
        query_list_t *findzone_q;
        query_list_t *lookup_q;
        query_list_t *countzone_q;
-       char *query_buf;
-       char *zone;
-       char *record;
-       char *client;
-       dlz_mutex_t lock;
+       char *        query_buf;
+       char *        zone;
+       char *        record;
+       char *        client;
+       dlz_mutex_t   lock;
        DLZ_LINK(dbinstance_t) link;
 };
 
index 6f0717c96f85da0cfe782c05448f05ac17d8684f..bac8ab12d19904ffacf1b97facd29718914df9f7 100644 (file)
@@ -28,6 +28,7 @@
 
 #include <inttypes.h>
 #include <stdbool.h>
+
 #include <sys/socket.h>
 #include <sys/types.h>
 #ifdef ISC_PLATFORM_HAVESYSUNH
@@ -38,7 +39,7 @@
 #include <netinet/in.h>
 
 typedef unsigned int isc_result_t;
-typedef uint32_t dns_ttl_t;
+typedef uint32_t     dns_ttl_t;
 
 /*
  * Define DLZ_DLOPEN_VERSION to different values to use older versions
@@ -81,7 +82,7 @@ typedef uint32_t dns_ttl_t;
        do {                           \
                union {                \
                        const void *k; \
-                       void *v;       \
+                       void *      v; \
                } _u;                  \
                _u.k = konst;          \
                var = _u.v;            \
@@ -100,37 +101,37 @@ typedef void *dns_dlzdb_t;
  */
 typedef struct isc_sockaddr {
        union {
-               struct sockaddr sa;
-               struct sockaddr_in sin;
+               struct sockaddr     sa;
+               struct sockaddr_in  sin;
                struct sockaddr_in6 sin6;
 #ifdef ISC_PLATFORM_HAVESYSUNH
                struct sockaddr_un sunix;
 #endif /* ifdef ISC_PLATFORM_HAVESYSUNH */
        } type;
        unsigned int length;
-       void *link;
+       void *       link;
 } isc_sockaddr_t;
 
 #define DNS_CLIENTINFO_VERSION 2
 typedef struct dns_clientinfo {
        uint16_t version;
-       void *data;
-       void *dbversion;
+       void *   data;
+       void *   dbversion;
 } dns_clientinfo_t;
 
 typedef isc_result_t (*dns_clientinfo_sourceip_t)(dns_clientinfo_t *client,
-                                                 isc_sockaddr_t **addrp);
+                                                 isc_sockaddr_t ** addrp);
 
 typedef isc_result_t (*dns_clientinfo_version_t)(dns_clientinfo_t *client,
-                                                void **addrp);
+                                                void **           addrp);
 
 #define DNS_CLIENTINFOMETHODS_VERSION 2
 #define DNS_CLIENTINFOMETHODS_AGE     1
 typedef struct dns_clientinfomethods {
-       uint16_t version;
-       uint16_t age;
+       uint16_t                  version;
+       uint16_t                  age;
        dns_clientinfo_sourceip_t sourceip;
-       dns_clientinfo_version_t dbversion;
+       dns_clientinfo_version_t  dbversion;
 } dns_clientinfomethods_t;
 #endif /* DLZ_DLOPEN_VERSION > 1 */
 
index 8061c92a1a5097fccf7d5f45b5dab41d39d6ccb2..be632eb073bbaef353ad26da7132d83c123ada26 100644 (file)
 
 #ifdef ISC_IRS_NEEDADDRINFO
 struct addrinfo {
-       int ai_flags;             /* AI_PASSIVE, AI_CANONNAME */
-       int ai_family;            /* PF_xxx */
-       int ai_socktype;          /* SOCK_xxx */
-       int ai_protocol;          /* 0 or IPPROTO_xxx for IPv4 and
-                                  * IPv6 */
-       size_t ai_addrlen;        /* Length of ai_addr */
-       char *ai_canonname;       /* Canonical name for hostname */
-       struct sockaddr *ai_addr; /* Binary address */
-       struct addrinfo *ai_next; /* Next structure in linked list */
+       int ai_flags;                  /* AI_PASSIVE, AI_CANONNAME */
+       int ai_family;                 /* PF_xxx */
+       int ai_socktype;               /* SOCK_xxx */
+       int ai_protocol;               /* 0 or IPPROTO_xxx for IPv4 and
+                                       * IPv6 */
+       size_t           ai_addrlen;   /* Length of ai_addr */
+       char *           ai_canonname; /* Canonical name for hostname */
+       struct sockaddr *ai_addr;      /* Binary address */
+       struct addrinfo *ai_next;      /* Next structure in linked list */
 };
 #endif /* ifdef ISC_IRS_NEEDADDRINFO */
 
index 4efa0303cb099d45289721fc05430b5c21e76f0b..d4488e2876aca11328ec5733eea5ec90fa3080ee 100644 (file)
@@ -52,7 +52,7 @@ extern pthread_mutexattr_t isc__mutex_attrs;
 typedef struct isc_mutexstats isc_mutexstats_t;
 
 typedef struct {
-       pthread_mutex_t mutex;   /*%< The actual mutex. */
+       pthread_mutex_t   mutex; /*%< The actual mutex. */
        isc_mutexstats_t *stats; /*%< Mutex statistics. */
 } isc_mutex_t;
 #else  /* if ISC_MUTEX_PROFILE */
index 89cd2637c7657af17cc09658188845a042b63b89..79f3e96ce2cbfcf1bc1890cd4ac68f78c1e00296 100644 (file)
@@ -26,8 +26,8 @@
 ISC_LANG_BEGINDECLS
 
 typedef pthread_t isc_thread_t;
-typedef void *isc_threadresult_t;
-typedef void *isc_threadarg_t;
+typedef void *   isc_threadresult_t;
+typedef void *   isc_threadarg_t;
 typedef isc_threadresult_t (*isc_threadfunc_t)(isc_threadarg_t);
 
 void
index 30fda926a96c5bfdc18f024a520c9b74a64c55be..5e5ef6f60d543711338b10e7d2ebd96f883ff6c7 100644 (file)
 /*! \file */
 
 #include <dirent.h>
-#include <sys/types.h> /* Required on some systems. */
 
 #include <isc/lang.h>
 #include <isc/platform.h>
 #include <isc/result.h>
 
+#include <sys/types.h> /* Required on some systems. */
+
 /*% Directory Entry */
 typedef struct isc_direntry {
-       char name[NAME_MAX];
+       char         name[NAME_MAX];
        unsigned int length;
 } isc_direntry_t;
 
 /*% Directory */
 typedef struct isc_dir {
-       unsigned int magic;
-       char dirname[PATH_MAX];
+       unsigned int   magic;
+       char           dirname[PATH_MAX];
        isc_direntry_t entry;
-       DIR *handle;
+       DIR *          handle;
 } isc_dir_t;
 
 ISC_LANG_BEGINDECLS
index f37c173b5837118738dca83163bdd9769b3c4cdd..b8cd5c87f6a4df8eb641e720ddd731f2726fd805 100644 (file)
 /***
  *** Imports.
  ***/
-#include <arpa/inet.h> /* Contractual promise. */
 #include <inttypes.h>
-#include <net/if.h>
-#include <netinet/in.h> /* Contractual promise. */
-#include <sys/socket.h> /* Contractual promise. */
-#include <sys/types.h>
 
 #include <isc/lang.h>
 #include <isc/platform.h>
 #include <isc/types.h>
 
+#include <arpa/inet.h> /* Contractual promise. */
+#include <net/if.h>
+#include <netinet/in.h> /* Contractual promise. */
+#include <sys/socket.h> /* Contractual promise. */
+#include <sys/types.h>
+
 #ifndef IN6ADDR_LOOPBACK_INIT
 #ifdef s6_addr
 /*% IPv6 address loopback init */
index 1c8dece3dbca2c60e205db4ef35781cbcaead66c..06d6aa36266cecd8dbcdd02dfc95efd258a10983 100644 (file)
@@ -18,6 +18,7 @@
  */
 #include <limits.h> /* Required for CHAR_BIT. */
 #include <stddef.h> /* For Linux Standard Base. */
+
 #include <sys/types.h>
 
 typedef off_t isc_offset_t;
index 7a75743eb2696895ed885adf4d6f4c3ca22d7e48..7339b87f913ec5ce1662675796bf47558b1be233 100644 (file)
@@ -73,11 +73,11 @@ enum memory_order {
 
 typedef enum memory_order memory_order;
 
-typedef int_fast32_t atomic_int_fast32_t;
+typedef int_fast32_t  atomic_int_fast32_t;
 typedef uint_fast32_t atomic_uint_fast32_t;
-typedef int_fast64_t atomic_int_fast64_t;
+typedef int_fast64_t  atomic_int_fast64_t;
 typedef uint_fast64_t atomic_uint_fast64_t;
-typedef bool atomic_bool;
+typedef bool         atomic_bool;
 
 typedef uint_fast64_t atomic_uintptr_t;
 
index 8a65323eb9bf374aaf67268fca1d58dbf81dd608..14c7cf634edff70cfff2661f45a6ea63bb66b2e1 100644 (file)
@@ -23,12 +23,12 @@ typedef struct isc_condition_thread isc_condition_thread_t;
 
 struct isc_condition_thread {
        unsigned long th;
-       HANDLE handle[2];
+       HANDLE        handle[2];
        ISC_LINK(isc_condition_thread_t) link;
 };
 
 typedef struct isc_condition {
-       HANDLE events[2];
+       HANDLE       events[2];
        unsigned int waiters;
        ISC_LIST(isc_condition_thread_t) threadlist;
 } isc_condition_t;
index a0f310752f0f24b2842ec1dff7fa7d250336fecc..fa6a72d6de815c6540048ee0328fdbecf6d80737 100644 (file)
 #include <isc/result.h>
 
 typedef struct {
-       char name[NAME_MAX];
-       unsigned int length;
+       char            name[NAME_MAX];
+       unsigned int    length;
        WIN32_FIND_DATA find_data;
 } isc_direntry_t;
 
 typedef struct {
-       unsigned int magic;
-       char dirname[PATH_MAX];
+       unsigned int   magic;
+       char           dirname[PATH_MAX];
        isc_direntry_t entry;
-       bool entry_filled;
-       HANDLE search_handle;
+       bool           entry_filled;
+       HANDLE         search_handle;
 } isc_dir_t;
 
 ISC_LANG_BEGINDECLS
index af0019ca43e596dd36705f1318690be78a0dc3ff..c6b56acd6a325ee3163b69e4ed0a0b5e4010b7cf 100644 (file)
@@ -76,7 +76,6 @@
 #define _WINSOCKAPI_ /* Prevent inclusion of winsock.h in windows.h */
 #endif              /* ifndef _WINSOCKAPI_ */
 
-#include <sys/types.h>
 #include <winsock2.h>
 #include <ws2tcpip.h>
 
@@ -84,6 +83,8 @@
 #include <isc/lang.h>
 #include <isc/types.h>
 
+#include <sys/types.h>
+
 /*
  * This is here because named client, interfacemgr.c, etc. use the name as
  * a variable
index 985d05aac5d43c76409e51f6e13404522be357f8..2e4090a6efdd25b81640da3711682a347fed9409 100644 (file)
@@ -16,6 +16,7 @@
  * File offsets are operating-system dependent.
  */
 #include <limits.h> /* Required for CHAR_BIT. */
+
 #include <sys/types.h>
 
 typedef _off_t isc_offset_t;
index 62ed255f55a62b72dccc6607b9dcb9143c64e9d0..15cf9b6f0bfc6cb48945d5b978358c6511930b17 100644 (file)
@@ -355,7 +355,7 @@ static inline bool
 atomic_compare_exchange_strong_explicit8(atomic_int_fast8_t *obj,
                                         int8_t *expected, int8_t desired,
                                         memory_order succ, memory_order fail) {
-       bool __r;
+       bool   __r;
        int8_t __v;
 
        UNUSED(succ);
@@ -375,7 +375,7 @@ atomic_compare_exchange_strong_explicit32(atomic_int_fast32_t *obj,
                                          int32_t *expected, int32_t desired,
                                          memory_order succ,
                                          memory_order fail) {
-       bool __r;
+       bool    __r;
        int32_t __v;
 
        UNUSED(succ);
@@ -411,7 +411,7 @@ atomic_compare_exchange_strong_explicit64(atomic_int_fast64_t *obj,
                                          int64_t *expected, int64_t desired,
                                          memory_order succ,
                                          memory_order fail) {
-       bool __r;
+       bool    __r;
        int64_t __v;
 
        UNUSED(succ);
index 43b79c6f8469283f7c1513a3c40729388990a00a..9ce612217a5eeb95e544722bbddc82cb12f66166 100644 (file)
@@ -62,8 +62,8 @@ WaitAbandonedIndex(DWORD dwWaitResult) {
 }
 
 typedef HANDLE isc_thread_t;
-typedef DWORD isc_threadresult_t;
-typedef void *isc_threadarg_t;
+typedef DWORD  isc_threadresult_t;
+typedef void * isc_threadarg_t;
 typedef isc_threadresult_t(WINAPI *isc_threadfunc_t)(isc_threadarg_t);
 
 #define isc_thread_self (unsigned long)GetCurrentThreadId