Assemble: don't leak memory with fdlist.

We should free fdlist when finished with it.

Signed-off-by: NeilBrown <neilb@suse.de>
This commit is contained in:
NeilBrown 2012-07-09 17:20:25 +10:00
parent 11b6d91dd0
commit 56dcaa6ba0
1 changed files with 1 additions and 0 deletions

View File

@ -1229,6 +1229,7 @@ int Assemble(struct supertype *st, char *mddev,
i--;
if (fdlist[i]>=0) close(fdlist[i]);
}
free(fdlist);
if (err) {
pr_err("Failed to restore critical section for reshape, sorry.\n");
if (c->backup_file == NULL)