Petr Štetiar
9b6ede0e53
avl: guard against theoretical null pointer dereference
...
clang-10 analyzer reports following:
avl.c:671:25: warning: Access to field 'parent' results in a dereference of a null pointer (loaded from field 'right')
node->right->parent = parent;
~~~~~ ^
Which seems to be impossible to trigger via exported AVL public API, but
it could be probably trigerred by fiddling with the AVL tree node struct
members manually as they are exposed.
Signed-off-by: Petr Štetiar <ynezz@true.cz>
2019-11-24 13:26:58 +01:00
Felix Fietkau
93b415c08d
list_compat.h: remove
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
2014-03-20 23:06:42 +01:00
Felix Fietkau
97ec6311f2
list_compat.h: remove list_remove()
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
2014-03-20 23:00:53 +01:00
Felix Fietkau
f5e105b603
list_compat.h: remove list_add_before()
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
2014-03-20 23:00:24 +01:00
Felix Fietkau
7673f2ab47
list_compat.h: remove list_add_after()
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
2014-03-20 22:59:26 +01:00
Felix Fietkau
fdcf117ff3
list_compat.h: remove list_add_head()
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
2014-03-20 22:58:21 +01:00
Felix Fietkau
d1e59653fa
list_compat.h: remove list_init_head()
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
2014-03-20 22:56:45 +01:00
Felix Fietkau
3edc29942c
avl.c: remove compat macros and switch to the argument order from list.h
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
2014-03-20 22:54:59 +01:00
Felix Fietkau
677e7bc0b3
make __avl_find_element() inline
2011-02-06 18:01:37 +01:00
Felix Fietkau
63cea8dcb7
update avl implementation from packetbb
2011-01-22 17:02:23 +01:00
Felix Fietkau
82ce342055
merge an avl list implementation (imported from PacketBB)
2010-12-28 23:59:06 +01:00