patch from Honza Horak using Coverity's static analysis tool.
This commit is contained in:
@@ -192,9 +192,10 @@ offset_to_lba(const udf_dirent_t *p_udf_dirent, off_t i_offset,
|
||||
*/
|
||||
*pi_max_size = 0;
|
||||
printf("Don't know how to data in ICB handle yet\n");
|
||||
|
||||
return CDIO_INVALID_LBA;
|
||||
case ICBTAG_FLAG_AD_EXTENDED:
|
||||
printf("Don't know how to handle extended addresses yet\n");
|
||||
return CDIO_INVALID_LBA;
|
||||
default:
|
||||
printf("Unsupported allocation descriptor %d\n", addr_ilk);
|
||||
return CDIO_INVALID_LBA;
|
||||
|
||||
@@ -658,8 +658,9 @@ udf_readdir(udf_dirent_t *p_udf_dirent)
|
||||
uint8_t data[UDF_BLOCKSIZE] = {0};
|
||||
udf_file_entry_t *p_udf_fe = (udf_file_entry_t *) &data;
|
||||
|
||||
udf_read_sectors(p_udf, p_udf_fe, p_udf->i_part_start
|
||||
+ p_udf_dirent->fid->icb.loc.lba, 1);
|
||||
if (DRIVER_OP_SUCCESS != udf_read_sectors(p_udf, p_udf_fe, p_udf->i_part_start
|
||||
+ p_udf_dirent->fid->icb.loc.lba, 1))
|
||||
return NULL;
|
||||
|
||||
memcpy(&(p_udf_dirent->fe), p_udf_fe,
|
||||
sizeof(udf_file_entry_t) + p_udf_fe->i_alloc_descs
|
||||
|
||||
Reference in New Issue
Block a user