Commit ed8f6866 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

fs-ext3-use-rbtree-postorder-iteration-helper-instead-of-opencoding-fix

use do{}while - more efficient and it squishes a coccinelle warning
Reported-by: default avatarFengguang Wu <fengguang.wu@intel.com>
Cc: Cody P Schafer <cody@linux.vnet.ibm.com>
Cc: Jan Kara <jack@suse.cz>
Cc: Michel Lespinasse <walken@google.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent b1c8047c
...@@ -312,11 +312,11 @@ static void free_rb_tree_fname(struct rb_root *root) ...@@ -312,11 +312,11 @@ static void free_rb_tree_fname(struct rb_root *root)
struct fname *fname, *next; struct fname *fname, *next;
rbtree_postorder_for_each_entry_safe(fname, next, root, rb_hash) rbtree_postorder_for_each_entry_safe(fname, next, root, rb_hash)
while (fname) { do {
struct fname * old = fname; struct fname *old = fname;
fname = fname->next; fname = fname->next;
kfree (old); kfree(old);
} } while (fname);
*root = RB_ROOT; *root = RB_ROOT;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment