Allowed writing with read displacement if target media is blank
This commit is contained in:
@ -549,13 +549,6 @@ int Xorriso_write_session(struct XorrisO *xorriso, int flag)
|
||||
char profile_name[80];
|
||||
IsoBoot *bootcat_node;
|
||||
|
||||
if(abs(xorriso->displacement_sign) == 1 && xorriso->displacement != 0) {
|
||||
sprintf(xorriso->info_text,
|
||||
"May not write session while -displacement is non-zero");
|
||||
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "FAILURE", 0);
|
||||
{ret= 0; goto ex;}
|
||||
}
|
||||
|
||||
ret= Xorriso_finish_hl_update(xorriso, 0);
|
||||
if(ret <= 0)
|
||||
return(ret);
|
||||
@ -574,7 +567,15 @@ int Xorriso_write_session(struct XorrisO *xorriso, int flag)
|
||||
if(ret<=0)
|
||||
return(0);
|
||||
|
||||
s= isoburn_disc_get_status(drive);
|
||||
if(xorriso->out_drive_handle == xorriso->in_drive_handle) {
|
||||
if(abs(xorriso->displacement_sign) == 1 && xorriso->displacement != 0 &&
|
||||
s != BURN_DISC_BLANK) {
|
||||
sprintf(xorriso->info_text,
|
||||
"May not grow ISO image while -displacement is non-zero");
|
||||
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "FAILURE", 0);
|
||||
{ret= 0; goto ex;}
|
||||
}
|
||||
source_drive= drive;
|
||||
} else {
|
||||
if(xorriso->in_drive_handle == NULL) {
|
||||
@ -585,7 +586,6 @@ int Xorriso_write_session(struct XorrisO *xorriso, int flag)
|
||||
if(ret<=0)
|
||||
goto ex;
|
||||
}
|
||||
s= isoburn_disc_get_status(drive);
|
||||
if(s!=BURN_DISC_BLANK) {
|
||||
s= burn_disc_get_status(drive);
|
||||
if(s!=BURN_DISC_BLANK)
|
||||
|
Reference in New Issue
Block a user