Skip to content
This repository has been archived by the owner on Dec 14, 2022. It is now read-only.

Commit

Permalink
rbtree/test: move rb_node to the middle of the test struct
Browse files Browse the repository at this point in the history
Avoid making the rb_node the first entry to catch some bugs around NULL
checking the rb_node.

Signed-off-by: Cody P Schafer <[email protected]>
Cc: Michel Lespinasse <[email protected]>
Cc: Jan Kara <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
codyps authored and torvalds committed Jan 24, 2014
1 parent 56abde7 commit dbf128c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/rbtree_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
#define CHECK_LOOPS 100

struct test_node {
struct rb_node rb;
u32 key;
struct rb_node rb;

/* following fields used for testing augmented rbtree functionality */
u32 val;
Expand Down

0 comments on commit dbf128c

Please sign in to comment.