From 646056fc6eeb81ffc4c4b15f06194ee60ec79202 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Sun, 23 May 2010 07:25:41 +0000 Subject: [PATCH] New write extension option isoburn_igopt_no_emul_toc --- libisoburn/trunk/libisoburn/isoburn.c | 14 +++++++++++++- libisoburn/trunk/libisoburn/isoburn.h | 5 +++++ libisoburn/trunk/libisoburn/libisoburn.h | 7 +++++++ libisoburn/trunk/xorriso/xorriso_timestamp.h | 2 +- 4 files changed, 26 insertions(+), 2 deletions(-) diff --git a/libisoburn/trunk/libisoburn/isoburn.c b/libisoburn/trunk/libisoburn/isoburn.c index 1141c0b5..2fbf46e7 100644 --- a/libisoburn/trunk/libisoburn/isoburn.c +++ b/libisoburn/trunk/libisoburn/isoburn.c @@ -465,6 +465,15 @@ int isoburn_prepare_disc_aux(struct burn_drive *in_d, struct burn_drive *out_d, opts->vol_expiration_time, opts->vol_effective_time, opts->vol_uuid); + if(opts->no_emul_toc) { + if(out_o->nwa == out_o->zero_nwa && + out_o->zero_nwa == Libisoburn_overwriteable_starT && + out_o->emulation_mode == 1) { + out_o->nwa= 0; + out_o->zero_nwa= 0; + out_o->min_start_byte= 0; + } + } ret = isoburn_disc_track_lba_nwa(out_d, NULL, 0, &lba, &nwa); opts->effective_lba= nwa; ret= isoburn_get_msc2(out_o, NULL, &nwa, 0); @@ -574,6 +583,7 @@ int isoburn_prepare_blind_grow(struct burn_drive *d, struct burn_disc **disc, o->nwa= o->zero_nwa= 0; else o->zero_nwa= 0; + o->min_start_byte= 0; ret= isoburn_prepare_disc_aux(d, out_drive, disc, opts, 2); if (ret<=0) return ret; @@ -908,6 +918,7 @@ int isoburn_igopt_set_extensions(struct isoburn_imgen_opts *o, int ext) o->aaip= !!(ext & 32); o->session_md5= !!(ext & 64); o->file_md5= (ext & (128 | 256)) >> 7; + o->no_emul_toc= !!(ext & 512); return(1); } @@ -916,7 +927,8 @@ int isoburn_igopt_get_extensions(struct isoburn_imgen_opts *o, int *ext) { *ext= (!!o->rockridge) | ((!!o->joliet)<<1) | ((!!o->iso1999)<<2) | ((!!o->hardlinks) << 3) | ((!!o->aaip) << 5) | - ((!!o->session_md5) << 6) | ((o->file_md5 & 3) << 7); + ((!!o->session_md5) << 6) | ((o->file_md5 & 3) << 7) | + ((!!o->no_emul_toc) << 9); return(1); } diff --git a/libisoburn/trunk/libisoburn/isoburn.h b/libisoburn/trunk/libisoburn/isoburn.h index 839f0a09..03323ecc 100644 --- a/libisoburn/trunk/libisoburn/isoburn.h +++ b/libisoburn/trunk/libisoburn/isoburn.h @@ -340,6 +340,11 @@ struct isoburn_imgen_opts { */ unsigned int file_md5 :2; + /* On overwriteable media or random access files do not write the first + session to LBA 32, but rather to LBA 0 directly. + */ + unsigned int no_emul_toc :1; + /* relaxed constraints */ /* diff --git a/libisoburn/trunk/libisoburn/libisoburn.h b/libisoburn/trunk/libisoburn/libisoburn.h index b3e4d3e7..97d130ae 100644 --- a/libisoburn/trunk/libisoburn/libisoburn.h +++ b/libisoburn/trunk/libisoburn/libisoburn.h @@ -945,6 +945,12 @@ int isoburn_igopt_get_level(struct isoburn_imgen_opts *o, int *level); compare this with the MD5 of the actual copying. If they do not match then issue MISHAP event. See also libisofs.h iso_write_opts_set_record_md5() + bit9= no_emul_toc + @since 0.5.8 + On overwriteable media or random access files do not write + the first session to LBA 32 and do not copy the first 64kB + of the first session to LBA 0, but rather write the first + session to LBA 0 directly. @return 1 success, <=0 failure */ #define isoburn_igopt_rockridge 1 @@ -955,6 +961,7 @@ int isoburn_igopt_get_level(struct isoburn_imgen_opts *o, int *level); #define isoburn_igopt_session_md5 64 #define isoburn_igopt_file_md5 128 #define isoburn_igopt_file_stability 256 +#define isoburn_igopt_no_emul_toc 512 int isoburn_igopt_set_extensions(struct isoburn_imgen_opts *o, int ext); int isoburn_igopt_get_extensions(struct isoburn_imgen_opts *o, int *ext); diff --git a/libisoburn/trunk/xorriso/xorriso_timestamp.h b/libisoburn/trunk/xorriso/xorriso_timestamp.h index c590d4fc..14f784ca 100644 --- a/libisoburn/trunk/xorriso/xorriso_timestamp.h +++ b/libisoburn/trunk/xorriso/xorriso_timestamp.h @@ -1 +1 @@ -#define Xorriso_timestamP "2010.05.21.134500" +#define Xorriso_timestamP "2010.05.23.072450"