* [PATCH] rbtree: fix typo in comment of __rb_insert()
@ 2014-07-22 5:58 Wei Yang
0 siblings, 0 replies; only message in thread
From: Wei Yang @ 2014-07-22 5:58 UTC (permalink / raw)
To: walken, akpm, xiaoguangrong; +Cc: linux-kernel, Wei Yang
In case 1, it passes down the BLACK color from G to p and u, and maintains the
color of n. By doing so, it maintains the black height of the sub-tree.
While in the comment, it marks the color of n to BLACK. This is a typo and not
consistents with the code.
This patch fixs this typo in comment.
Signed-off-by: Wei Yang <weiyang@linux.vnet.ibm.com>
---
lib/rbtree.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/rbtree.c b/lib/rbtree.c
index 65f4eff..c16c81a 100644
--- a/lib/rbtree.c
+++ b/lib/rbtree.c
@@ -101,7 +101,7 @@ __rb_insert(struct rb_node *node, struct rb_root *root,
* / \ / \
* p u --> P U
* / /
- * n N
+ * n n
*
* However, since g's parent might be red, and
* 4) does not allow this, we need to recurse
--
1.7.9.5
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2014-07-22 5:59 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-07-22 5:58 [PATCH] rbtree: fix typo in comment of __rb_insert() Wei Yang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®