From cd5178909dd050ed3b185d9206dab0565c61dd1a Mon Sep 17 00:00:00 2001 From: "Liam R. Howlett" Date: Mon, 22 Nov 2021 09:22:53 -0500 Subject: [PATCH] maple_tree: Small clean up for mas_spanning_store() Signed-off-by: Liam R. Howlett --- lib/maple_tree.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/maple_tree.c b/lib/maple_tree.c index fc4b8799f20b..a77208d3c6f5 100644 --- a/lib/maple_tree.c +++ b/lib/maple_tree.c @@ -3828,6 +3828,7 @@ static inline int mas_spanning_store(struct ma_state *mas, void *entry) int node_count = 1 + height * 3; void *content, *r_content; unsigned long r_min, r_max; + unsigned char l_end; /* Holds new left and right sub-tree */ MA_STATE(l_mas, mas->tree, mas->index, mas->index); @@ -3877,8 +3878,8 @@ static inline int mas_spanning_store(struct ma_state *mas, void *entry) } /* Copy l_mas and store the value in b_node. */ - b_node.b_end = mas_store_b_node(&l_mas, &b_node, entry, - mas_data_end(&l_mas), mas_data_end(&l_mas), + l_end = mas_data_end(&l_mas); + b_node.b_end = mas_store_b_node(&l_mas, &b_node, entry, l_end, l_end, content); /* Copy r_mas into b_node. */ mas_mab_cp(&r_mas, r_mas.offset, mt_slot_count(r_mas.node), -- 2.50.1