]> git.sur5r.net Git - openldap/blobdiff - include/avl.h
lber.h: added #include <stddef.h> conditional on LBER_SIZE_T_DEFINED
[openldap] / include / avl.h
index 58b3d972dec206eddb27c9fbd02ca0e19263cc9e..fe90302fb31cb30e072234979ca66f6b4401051d 100644 (file)
 
 LDAP_BEGIN_DECL
 
-typedef struct avlnode {
+typedef struct avlnode Avlnode;
+
+#ifdef AVL_INTERNAL
+struct avlnode {
        void*           avl_data;
-       signed char             avl_bf;
+       signed int              avl_bf;
        struct avlnode  *avl_left;
        struct avlnode  *avl_right;
-} Avlnode;
+};
 
 #define NULLAVL        ((Avlnode *) NULL)
 
@@ -50,6 +53,8 @@ typedef struct avlnode {
 #define avl_getone(x)  ((x) == 0 ? 0 : (x)->avl_data)
 #define avl_onenode(x) ((x) == 0 || ((x)->avl_left == 0 && (x)->avl_right == 0))
 
+#endif /* AVL_INTERNALS */
+
 typedef int            (*AVL_APPLY) LDAP_P((void *, void*));
 typedef int            (*AVL_CMP) LDAP_P((void*, void*));
 typedef int            (*AVL_DUP) LDAP_P((void*, void*));