Properly initialize an error variable to avoid returning uninitialized
data when 'show drives' succeeds, often resulting in a failing exit code even though the command worked fine. Reviewed by: bz Approved by: re (kib) MFC after: 3 days
This commit is contained in:
parent
ec3e6e77a1
commit
c0ca022a34
@ -533,6 +533,7 @@ show_drives(int ac, char **av)
|
||||
MFI_DNAME_ES));
|
||||
printf("\n");
|
||||
}
|
||||
error = 0;
|
||||
error:
|
||||
free(list);
|
||||
close(fd);
|
||||
|
Loading…
Reference in New Issue
Block a user