Provisory new -e pseudo path --interval:appened_partition_N:all::

This commit is contained in:
2015-12-30 18:04:16 +00:00
parent 2afe09e42a
commit 885ef25be3
4 changed files with 106 additions and 20 deletions

View File

@ -2384,7 +2384,7 @@ problem_handler_2:;
xorriso->boot_image_emul= 2;
}
boot_path[0]= 0;
if(argv[i][0] != '/')
if(argv[i][0] != '/' && strncmp(argv[i], "--interval:", 11) != 0)
strcat(boot_path, "/");
ret= Sfile_str(boot_path + strlen(boot_path), argv[i], 0);
if(ret <= 0)

View File

@ -607,14 +607,14 @@ int Xorriso_attach_boot_image(struct XorrisO *xorriso, int flag)
struct burn_drive_info *source_dinfo;
struct burn_drive *source_drive;
IsoImage *image= NULL;
IsoNode *node;
IsoNode *node= NULL;
ElToritoBootImage *bootimg;
enum eltorito_boot_media_type emul_type= ELTORITO_NO_EMUL;
char *bin_path;
int emul, platform_id;
off_t load_size;
struct stat stbuf;
int hflag= 0;
int hflag= 0, is_interval= 0;
if(xorriso->boot_image_bin_path[0] == 0 && !(flag & 2)) {
@ -647,13 +647,18 @@ int Xorriso_attach_boot_image(struct XorrisO *xorriso, int flag)
emul= xorriso->boot_image_emul;
platform_id= xorriso->boot_platform_id;
load_size= xorriso->boot_image_load_size;
if(strncmp(bin_path, "--interval:appended_partition_", 30) == 0) {
is_interval= 1;
if(load_size <= 0)
load_size= 512;
}
if(xorriso->boot_efi_default) {
emul= 0;
platform_id= 0xef;
xorriso->patch_isolinux_image= (xorriso->patch_isolinux_image & ~3) | 0;
}
if(platform_id == 0xef || load_size < 0) {
if((platform_id == 0xef || load_size < 0) && !is_interval) {
ret= Xorriso_iso_lstat(xorriso, bin_path, &stbuf, 2 | 4);
if(ret != 0)
{ret= 0; goto ex;}
@ -671,13 +676,15 @@ int Xorriso_attach_boot_image(struct XorrisO *xorriso, int flag)
else if(emul == 2)
emul_type= ELTORITO_FLOPPY_EMUL;
ret= Xorriso_node_from_path(xorriso, image, bin_path, &node, 1);
if(ret <= 0) {
sprintf(xorriso->info_text,
"Cannot find in ISO image: -boot_image ... bin_path=");
Text_shellsafe(bin_path, xorriso->info_text, 1);
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "FAILURE", 0);
{ret= 0; goto ex;}
if (!is_interval) {
ret= Xorriso_node_from_path(xorriso, image, bin_path, &node, 1);
if(ret <= 0) {
sprintf(xorriso->info_text,
"Cannot find in ISO image: -boot_image ... bin_path=");
Text_shellsafe(bin_path, xorriso->info_text, 1);
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "FAILURE", 0);
{ret= 0; goto ex;}
}
}
if(xorriso->boot_count == 0) {

View File

@ -1 +1 @@
#define Xorriso_timestamP "2015.12.26.090812"
#define Xorriso_timestamP "2015.12.30.175951"