Commit 0010f18a authored by Artem Bityutskiy's avatar Artem Bityutskiy

UBIFS: minor tweaks in commit

No functional changes, just lessen the amount of indentations.
Signed-off-by: default avatarArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
parent b364b41a
...@@ -372,12 +372,15 @@ static int layout_in_gaps(struct ubifs_info *c, int cnt) ...@@ -372,12 +372,15 @@ static int layout_in_gaps(struct ubifs_info *c, int cnt)
written = layout_leb_in_gaps(c, p); written = layout_leb_in_gaps(c, p);
if (written < 0) { if (written < 0) {
err = written; err = written;
if (err == -ENOSPC) { if (err != -ENOSPC) {
kfree(c->gap_lebs);
c->gap_lebs = NULL;
return err;
}
if (!dbg_force_in_the_gaps_enabled) { if (!dbg_force_in_the_gaps_enabled) {
/* /*
* Do not print scary warnings if the * Do not print scary warnings if the debugging
* debugging option which forces * option which forces in-the-gaps is enabled.
* in-the-gaps is enabled.
*/ */
ubifs_err("out of space"); ubifs_err("out of space");
spin_lock(&c->space_lock); spin_lock(&c->space_lock);
...@@ -389,10 +392,6 @@ static int layout_in_gaps(struct ubifs_info *c, int cnt) ...@@ -389,10 +392,6 @@ static int layout_in_gaps(struct ubifs_info *c, int cnt)
err = 0; err = 0;
break; break;
} }
kfree(c->gap_lebs);
c->gap_lebs = NULL;
return err;
}
p++; p++;
cnt -= written; cnt -= written;
leb_needed_cnt = get_leb_cnt(c, cnt); leb_needed_cnt = get_leb_cnt(c, cnt);
......
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