Added some #ifndefs to stop files being included multiple times.
authorMartin Schwenke <martin@meltin.net>
Fri, 11 Nov 2011 01:41:24 +0000 (12:41 +1100)
committerMartin Schwenke <martin@meltin.net>
Fri, 11 Nov 2011 03:31:50 +0000 (14:31 +1100)
Signed-off-by: Martin Schwenke <martin@meltin.net>
common/rb_tree.h
include/includes.h
lib/util/db_wrap.h
tcp/ctdb_tcp.h

index 4f2ab22d36dd8b846f7b32130f980cac064d9ac5..b5ddbb2a2b2df80cc39c69c26a4e6faf5efda64e 100644 (file)
@@ -17,8 +17,9 @@
    along with this program; if not, see <http://www.gnu.org/licenses/>.
 */
 
-
-
+#ifndef _RB_TREE_H
+#define _RB_TREE_H
 #define TRBT_RED               0x00
 #define TRBT_BLACK             0x01
 typedef struct trbt_node {
@@ -85,3 +86,5 @@ int trbt_traversearray32(trbt_tree_t *tree, uint32_t keylen, int (*callback)(voi
 /* Lookup the first node in the tree with a key based on an array of uint32 
    and return a pointer to data or NULL */
 void *trbt_findfirstarray32(trbt_tree_t *tree, uint32_t keylen);
+
+#endif /* _RB_TREE_H */
index b3f8eb941b22ad6cce91a7180a3db6bf2f9e6677..b7d1e76eb851226f327dd2c36b3faf83f79a0677 100644 (file)
@@ -1,3 +1,6 @@
+#ifndef _CTDB_INCLUDES_H
+#define _CTDB_INCLUDES_H
+
 #define HAVE_UNIXSOCKET 1
 
 #include "replace.h"
@@ -58,3 +61,5 @@ _PUBLIC_ int set_blocking(int fd, BOOL set);
 
 #include "lib/util/debug.h"
 #include "lib/util/util.h"
+
+#endif /* _CTDB_INCLUDES_H */
index 6ab93624744ced2ec5a5b2dab11eabf731c7431f..5ae5fd10ae3dc9dbd10f771c682c6ee2e786b3a3 100644 (file)
@@ -19,6 +19,8 @@
    along with this program; if not, see <http://www.gnu.org/licenses/>.
 */
 
+#ifndef _DB_WRAP_H
+#define _DB_WRAP_H
 
 struct tdb_wrap {
        struct tdb_context *tdb;
@@ -30,3 +32,5 @@ struct tdb_wrap {
 struct tdb_wrap *tdb_wrap_open(TALLOC_CTX *mem_ctx,
                               const char *name, int hash_size, int tdb_flags,
                               int open_flags, mode_t mode);
+
+#endif /* _DB_WRAP_H */
index 9a17bd6b5961a2fb6a7dbdc9a313df0473d6f98d..5b6b6516b70c73fbcf2ff5118b867a75f2c5e534 100644 (file)
@@ -17,7 +17,9 @@
    along with this program; if not, see <http://www.gnu.org/licenses/>.
 */
 
-
+#ifndef _CTDB_TCP_H
+#define _CTDB_TCP_H
 /* ctdb_tcp main state */
 struct ctdb_tcp {
        struct ctdb_context *ctdb;
@@ -54,3 +56,5 @@ void ctdb_tcp_tnode_cb(uint8_t *data, size_t cnt, void *private_data);
 void ctdb_tcp_stop_connection(struct ctdb_node *node);
 
 #define CTDB_TCP_ALIGNMENT 8
+
+#endif /* _CTDB_TCP_H */