Skip to content

Commit

Permalink
prio_tree: remove unnecessary code in prio_tree_replace
Browse files Browse the repository at this point in the history
Remove the code since 'node' has already been initialized in the begin of
the function

Signed-off-by: Xiao Guangrong <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Xiao Guangrong authored and torvalds committed Mar 23, 2012
1 parent f43804b commit f42240d
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion lib/prio_tree.c
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,6 @@ struct prio_tree_node *prio_tree_replace(struct prio_tree_root *root,
* We can reduce root->index_bits here. However, it is complex
* and does not help much to improve performance (IMO).
*/
node->parent = node;
root->prio_tree_node = node;
} else {
node->parent = old->parent;
Expand Down

0 comments on commit f42240d

Please sign in to comment.