diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2014-07-23 12:53:08 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2014-07-23 12:53:08 +0100 |
commit | fe79d8c5a39f2b717f78cc3f3ef21b3cfc46500b (patch) | |
tree | c84e6a5d4c5cd78a7a2cc3c7adbc7af5d0541682 /src/libutil/radix.h | |
parent | e0483657ff6cf1adc828ccce457814d61fe90a0d (diff) | |
download | rspamd-fe79d8c5a39f2b717f78cc3f3ef21b3cfc46500b.tar.gz rspamd-fe79d8c5a39f2b717f78cc3f3ef21b3cfc46500b.zip |
Revert "Unify code style."
This reverts commit e0483657ff6cf1adc828ccce457814d61fe90a0d.
Diffstat (limited to 'src/libutil/radix.h')
-rw-r--r-- | src/libutil/radix.h | 38 |
1 files changed, 13 insertions, 25 deletions
diff --git a/src/libutil/radix.h b/src/libutil/radix.h index cfdefa25b..88f345e3d 100644 --- a/src/libutil/radix.h +++ b/src/libutil/radix.h @@ -7,30 +7,29 @@ #define RADIX_NO_VALUE (uintptr_t)-1 -typedef struct radix_node_s radix_node_t; +typedef struct radix_node_s radix_node_t; struct radix_node_s { - radix_node_t *right; - radix_node_t *left; - radix_node_t *parent; - uintptr_t value; + radix_node_t *right; + radix_node_t *left; + radix_node_t *parent; + uintptr_t value; guint32 key; }; typedef struct { - radix_node_t *root; - size_t size; + radix_node_t *root; + size_t size; rspamd_mempool_t *pool; } radix_tree_t; -typedef gboolean (*radix_tree_traverse_func)(guint32 key, guint32 mask, - uintptr_t value, void *user_data); +typedef gboolean (*radix_tree_traverse_func)(guint32 key, guint32 mask, uintptr_t value, void *user_data); /** * Create new radix tree */ -radix_tree_t * radix_tree_create (void); +radix_tree_t *radix_tree_create (void); /** * Insert value to radix tree @@ -38,10 +37,7 @@ radix_tree_t * radix_tree_create (void); * 0 if operation was successfull * -1 if there was some error */ -gint radix32tree_insert (radix_tree_t *tree, - guint32 key, - guint32 mask, - uintptr_t value); +gint radix32tree_insert (radix_tree_t *tree, guint32 key, guint32 mask, uintptr_t value); /** * Add value to radix tree or insert it if value does not exists @@ -49,10 +45,7 @@ gint radix32tree_insert (radix_tree_t *tree, * 0 if value was inserted * -1 if there was some error */ -uintptr_t radix32tree_add (radix_tree_t *tree, - guint32 key, - guint32 mask, - uintptr_t value); +uintptr_t radix32tree_add (radix_tree_t *tree, guint32 key, guint32 mask, uintptr_t value); /** * Replace value in radix tree or insert it if value does not exists @@ -60,10 +53,7 @@ uintptr_t radix32tree_add (radix_tree_t *tree, * 0 if value was inserted * -1 if there was some error */ -gint radix32tree_replace (radix_tree_t *tree, - guint32 key, - guint32 mask, - uintptr_t value); +gint radix32tree_replace (radix_tree_t *tree, guint32 key, guint32 mask, uintptr_t value); /** * Delete value from radix tree @@ -91,9 +81,7 @@ uintptr_t radix32_tree_find_addr (radix_tree_t *tree, rspamd_inet_addr_t *addr); /** * Traverse via the whole tree calling specified callback */ -void radix32tree_traverse (radix_tree_t *tree, - radix_tree_traverse_func func, - void *user_data); +void radix32tree_traverse (radix_tree_t *tree, radix_tree_traverse_func func, void *user_data); /** * Frees radix tree |