Enabled multi-session with partition offset
This commit is contained in:
@ -155,7 +155,7 @@ int Xorriso_aquire_drive(struct XorrisO *xorriso, char *adr, int flag)
|
||||
{
|
||||
int ret, hret, not_writeable= 0, has_what, aquire_flag, load_lba, ext;
|
||||
int lba, track, session, params_flag, adr_mode, read_ret;
|
||||
uint32_t size;
|
||||
uint32_t size, offst;
|
||||
struct burn_drive_info *dinfo= NULL, *out_dinfo, *in_dinfo;
|
||||
struct burn_drive *drive= NULL, *out_drive, *in_drive;
|
||||
enum burn_disc_status state;
|
||||
@ -233,6 +233,16 @@ int Xorriso_aquire_drive(struct XorrisO *xorriso, char *adr, int flag)
|
||||
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "FAILURE", 0);
|
||||
ret= 0; goto ex;
|
||||
}
|
||||
|
||||
state= isoburn_disc_get_status(dinfo[0].drive);
|
||||
ret= isoburn_get_img_partition_offset(dinfo[0].drive, &offst);
|
||||
if((state == BURN_DISC_APPENDABLE || state == BURN_DISC_FULL) && ret == 1) {
|
||||
sprintf(xorriso->info_text,
|
||||
"ISO image bears MBR with -boot_image any partition_offset=%lu",
|
||||
(unsigned long) offst);
|
||||
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "NOTE", 0);
|
||||
}
|
||||
|
||||
if(flag&1)
|
||||
if(xorriso->image_start_mode&(1<<31)) /* used up setting */
|
||||
xorriso->image_start_mode= 0; /* no need to perform auto setting */
|
||||
@ -242,6 +252,8 @@ int Xorriso_aquire_drive(struct XorrisO *xorriso, char *adr, int flag)
|
||||
xorriso->outdev_is_exclusive= xorriso->drives_exclusive;
|
||||
}
|
||||
drive= dinfo[0].drive;
|
||||
state= isoburn_disc_get_status(drive);
|
||||
Xorriso_process_msg_queues(xorriso,0);
|
||||
if(flag&1) {
|
||||
if(xorriso->image_start_mode&(1<<31)) /* used up setting */
|
||||
xorriso->image_start_mode&= ~0xffff; /* perform auto setting */
|
||||
@ -279,8 +291,6 @@ int Xorriso_aquire_drive(struct XorrisO *xorriso, char *adr, int flag)
|
||||
xorriso->image_start_mode|= (1<<31); /* mark as used up */
|
||||
}
|
||||
}
|
||||
state= isoburn_disc_get_status(drive);
|
||||
Xorriso_process_msg_queues(xorriso,0);
|
||||
if(flag&1) {
|
||||
volset= isoburn_get_attached_image(drive);
|
||||
if(volset != NULL) { /* The image object is already created */
|
||||
|
Reference in New Issue
Block a user