Record size 0 with oversized EFI boot images to span them up to end of medium
This commit is contained in:
parent
fdf10cadc1
commit
d87990de2c
@ -729,9 +729,16 @@ int Xorriso_attach_boot_image(struct XorrisO *xorriso, int flag)
|
|||||||
el_torito_set_boot_platform_id(bootimg, (uint8_t) platform_id);
|
el_torito_set_boot_platform_id(bootimg, (uint8_t) platform_id);
|
||||||
if(load_size / 512 > 65535) {
|
if(load_size / 512 > 65535) {
|
||||||
sprintf(xorriso->info_text,
|
sprintf(xorriso->info_text,
|
||||||
"Boot image load size exceeds 65535 blocks. Will record 65535 in El Torito.");
|
"Boot image load size exceeds 65535 blocks of 512 bytes. ");
|
||||||
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "WARNING", 0);
|
if(platform_id == 0xef) {
|
||||||
|
strcat(xorriso->info_text,
|
||||||
|
"Will record 0 in El Torito to extend ESP to end-of-medium.");
|
||||||
|
load_size= 0;
|
||||||
|
} else {
|
||||||
|
strcat(xorriso->info_text, "Will record 65535 in El Torito.");
|
||||||
load_size= 65535 * 512;
|
load_size= 65535 * 512;
|
||||||
|
}
|
||||||
|
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "WARNING", 0);
|
||||||
}
|
}
|
||||||
/* The function will understand negative short as positive unsigned */
|
/* The function will understand negative short as positive unsigned */
|
||||||
el_torito_set_load_size(bootimg, (short) (load_size / 512));
|
el_torito_set_load_size(bootimg, (short) (load_size / 512));
|
||||||
|
@ -1 +1 @@
|
|||||||
#define Xorriso_timestamP "2015.10.18.130151"
|
#define Xorriso_timestamP "2015.10.23.085903"
|
||||||
|
Loading…
Reference in New Issue
Block a user