rbheap: Fix rtems_rbheap_free()

Remove unused descriptor of merged free chunks from the free chain and
add them to the spare descriptors.

Update #2417.
This commit is contained in:
Sebastian Huber
2015-09-11 10:42:06 +02:00
parent deb3f298d1
commit edf77328c1
2 changed files with 20 additions and 23 deletions

View File

@@ -171,6 +171,11 @@ static void test_chunk_tree(
.chunk_end = chunk_begin + chunk_count
};
rtems_test_assert(
rtems_chain_node_count_unprotected(&control->spare_descriptor_chain)
== PAGE_COUNT - chunk_count
);
_RBTree_Iterate(
&control->chunk_tree,
RBT_RIGHT,