summaryrefslogtreecommitdiffstats
path: root/fs/ext3/dir.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ext3/dir.c')
-rw-r--r--fs/ext3/dir.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/ext3/dir.c b/fs/ext3/dir.c
index a331ad1c23f8..e66e4808719f 100644
--- a/fs/ext3/dir.c
+++ b/fs/ext3/dir.c
@@ -312,11 +312,11 @@ static void free_rb_tree_fname(struct rb_root *root)
struct fname *fname, *next;
rbtree_postorder_for_each_entry_safe(fname, next, root, rb_hash)
- while (fname) {
- struct fname * old = fname;
+ do {
+ struct fname *old = fname;
fname = fname->next;
- kfree (old);
- }
+ kfree(old);
+ } while (fname);
*root = RB_ROOT;
}
OpenPOWER on IntegriCloud