In 0.83git now. Fix minor leaks in libcdio 0.82 detected by cppcheck
via Eric Sesterhenn.
This commit is contained in:
@@ -737,6 +737,7 @@ close_tray_freebsd (const char *psz_device)
|
||||
|
||||
if((i_rc = ioctl(fd, CDIOCCLOSE)) != 0) {
|
||||
cdio_warn ("ioctl CDIOCCLOSE failed: %s\n", strerror(errno));
|
||||
close(fd);
|
||||
return DRIVER_OP_ERROR;
|
||||
}
|
||||
close(fd);
|
||||
|
||||
@@ -439,6 +439,8 @@ cdio_close_tray (const char *psz_orig_drive, /*in/out*/ driver_id_t
|
||||
free(psz_drive);
|
||||
return drc;
|
||||
}
|
||||
|
||||
free(psz_drive);
|
||||
return DRIVER_OP_UNSUPPORTED;
|
||||
}
|
||||
|
||||
|
||||
@@ -356,6 +356,7 @@ eject_media_netbsd(void *user_data) {
|
||||
ret = 1;
|
||||
}
|
||||
|
||||
close(fd);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user