mirror of https://github.com/vitalif/e2fsprogs
e2fsck: fix possible double free when searching for config file
This happens if there is an error while scanning a directory for config file fragments. This is rarely used, which is why we didn't notice this. Addresses-Coverity-Bug: #1138576 Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>maint-test
parent
b34b94d5cd
commit
603fc2cb4b
|
@ -320,6 +320,7 @@ profile_init(const char **files, profile_t *ret_profile)
|
|||
for (fs = files; !PROFILE_LAST_FILESPEC(*fs); fs++) {
|
||||
if (array)
|
||||
free_list(array);
|
||||
array = NULL;
|
||||
retval = get_dirlist(*fs, &array);
|
||||
if (retval == 0) {
|
||||
if (!array)
|
||||
|
|
Loading…
Reference in New Issue