setup: fix memory leak
Found by: Coverity scan. CID: 73680, 73715
This commit is contained in:
parent
67d9ce82ac
commit
57e7f1b775
1 changed files with 4 additions and 0 deletions
|
@ -353,6 +353,10 @@ SETUP (const char *dir,
|
|||
}
|
||||
grub_util_info ("guessed root_dev `%s' from "
|
||||
"dir `%s'", root_dev->disk->name, dir);
|
||||
|
||||
for (cur = root_devices; *cur; cur++)
|
||||
free (*cur);
|
||||
free (root_devices);
|
||||
}
|
||||
|
||||
grub_util_info ("setting the root device to `%s'", root);
|
||||
|
|
Loading…
Reference in a new issue