Re-enabled recognition of missiong or empty disk files as blank drive (rev 2997)
This commit is contained in:
parent
801828fd5c
commit
dd30d37625
@ -326,7 +326,9 @@ int isoburn_start_emulation(struct isoburn *o, int flag)
|
||||
*/
|
||||
role = burn_drive_get_drive_role(drive);
|
||||
ret = burn_get_read_capacity(drive, &capacity, 0);
|
||||
if ((ret > 0 && capacity > 0) || role == 2) {
|
||||
if (ret <= 0)
|
||||
capacity = -1;
|
||||
if (capacity > 0 || role == 2) {
|
||||
/* Might be a block device on a system where libburn cannot determine its
|
||||
size. Try to read anyway. */
|
||||
memset(o->target_iso_head, 0, Libisoburn_target_head_sizE);
|
||||
@ -336,8 +338,11 @@ int isoburn_start_emulation(struct isoburn *o, int flag)
|
||||
ret = burn_read_data(drive, (off_t) 0, (char*)o->target_iso_head,
|
||||
to_read, &data_count, 2);
|
||||
if (ret <= 0) {
|
||||
/* an error means a full disc with no ISO image */
|
||||
o->fabricated_disc_status= BURN_DISC_FULL;
|
||||
/* an error means a disc with no ISO image */
|
||||
if (capacity > 0)
|
||||
o->fabricated_disc_status= BURN_DISC_FULL;
|
||||
else
|
||||
o->fabricated_disc_status= BURN_DISC_BLANK;
|
||||
return 1;
|
||||
}
|
||||
} else {
|
||||
|
@ -1 +1 @@
|
||||
#define Xorriso_timestamP "2010.01.01.130215"
|
||||
#define Xorriso_timestamP "2010.01.11.113303"
|
||||
|
Loading…
Reference in New Issue
Block a user