mirror of
https://gitlab.com/qemu-project/openbios.git
synced 2024-02-13 08:34:06 +08:00
Add checks for open_ih() return value
Signed-off-by: Blue Swirl <blauwirbel@gmail.com> git-svn-id: svn://coreboot.org/openbios/trunk/openbios-devel@842 f158a5a8-5612-0410-a976-696ce0be7e32
This commit is contained in:
@@ -219,10 +219,14 @@ iso9660_files_probe( iso9660_info_t *dummy )
|
||||
int fd, ret = 0;
|
||||
|
||||
fd = open_ih(ih);
|
||||
if (iso9660_probe(fd, offs))
|
||||
ret = -1;
|
||||
|
||||
close_io(fd);
|
||||
if (fd >= 0) {
|
||||
if (iso9660_probe(fd, offs)) {
|
||||
ret = -1;
|
||||
}
|
||||
close_io(fd);
|
||||
} else {
|
||||
ret = -1;
|
||||
}
|
||||
|
||||
RET (ret);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user