New -early_stdio_test option appendable_wo

This commit is contained in:
Thomas Schmitt 2011-03-21 16:55:18 +00:00
parent e8800be3d2
commit 1523d2bdd9
8 changed files with 68 additions and 51 deletions

View File

@ -225,7 +225,7 @@ int Xorriso_aquire_drive(struct XorrisO *xorriso, char *adr, int flag)
if((xorriso->ino_behavior & (1 | 2)) && !(xorriso->do_aaip & (4 | 32))) if((xorriso->ino_behavior & (1 | 2)) && !(xorriso->do_aaip & (4 | 32)))
aquire_flag|= 64; aquire_flag|= 64;
burn_preset_device_open(xorriso->drives_exclusive, 0, 0); burn_preset_device_open(xorriso->drives_exclusive, 0, 0);
burn_allow_drive_role_4(1 | (xorriso->early_stdio_test & 6)); burn_allow_drive_role_4(1 | (xorriso->early_stdio_test & 14));
ret= isoburn_drive_aquire(&dinfo, libburn_adr, aquire_flag); ret= isoburn_drive_aquire(&dinfo, libburn_adr, aquire_flag);
burn_preset_device_open(1, 0, 0); burn_preset_device_open(1, 0, 0);
Xorriso_process_msg_queues(xorriso,0); Xorriso_process_msg_queues(xorriso,0);

View File

@ -308,6 +308,8 @@ int Xorriso_option_early_stdio_test(struct XorrisO *xorriso, char *mode,
xorriso->early_stdio_test= 2 | 4; xorriso->early_stdio_test= 2 | 4;
else if(strcmp(mode, "off") == 0) else if(strcmp(mode, "off") == 0)
xorriso->early_stdio_test= 0; xorriso->early_stdio_test= 0;
else if(strcmp(mode, "appendable_wo") == 0)
xorriso->early_stdio_test= 2 | 4 | 8;
else { else {
sprintf(xorriso->info_text, "-early_stdio_test: unknown mode '%s'", mode); sprintf(xorriso->info_text, "-early_stdio_test: unknown mode '%s'", mode);
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "SORRY", 0); Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "SORRY", 0);
@ -1431,7 +1433,7 @@ int Xorriso_option_help(struct XorrisO *xorriso, int flag)
" Enable production of scdbackup tag with -md5 on", " Enable production of scdbackup tag with -md5 on",
" -ban_stdio_write", " -ban_stdio_write",
" Allow for writing only the usage of optical drives.", " Allow for writing only the usage of optical drives.",
" -early_stdio_test", " -early_stdio_test \"on\"|\"appendable_wo\"|\"off\"",
" Classify stdio drives by effective access permissions.", " Classify stdio drives by effective access permissions.",
" -blank \"fast\"|\"all\"|\"deformat\"|\"deformat_quickest\"", " -blank \"fast\"|\"all\"|\"deformat\"|\"deformat_quickest\"",
" Blank media resp. invalidate ISO image on media.", " Blank media resp. invalidate ISO image on media.",

View File

@ -1242,9 +1242,10 @@ int Xorriso_status(struct XorrisO *xorriso, char *filter, FILE *fp, int flag)
Xorriso_status_result(xorriso,filter,fp,flag&2); Xorriso_status_result(xorriso,filter,fp,flag&2);
} }
is_default= ((xorriso->early_stdio_test & 6) == 0); is_default= ((xorriso->early_stdio_test & 14) == 0);
sprintf(line, "-early_stdio_test %s\n", sprintf(line, "-early_stdio_test %s\n",
xorriso->early_stdio_test & 6 ? "on" : "off"); xorriso->early_stdio_test & 6 ? xorriso->early_stdio_test & 8 ?
"appendable_wo" : "on" : "off");
if(!(is_default && no_defaults)) if(!(is_default && no_defaults))
Xorriso_status_result(xorriso,filter,fp,flag&2); Xorriso_status_result(xorriso,filter,fp,flag&2);

View File

@ -9,7 +9,7 @@
.\" First parameter, NAME, should be all caps .\" First parameter, NAME, should be all caps
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
.\" other parameters are allowed: see man(7), man(1) .\" other parameters are allowed: see man(7), man(1)
.TH XORRISO 1 "Mar 09, 2011" .TH XORRISO 1 "Mar 21, 2011"
.\" Please adjust this date whenever revising the manpage. .\" Please adjust this date whenever revising the manpage.
.\" .\"
.\" Some roff macros, for reference: .\" Some roff macros, for reference:
@ -873,7 +873,7 @@ Allow for writing only the usage of MMC optical drives. Disallow
to write the result into files of nearly arbitrary type. to write the result into files of nearly arbitrary type.
Once set, this command cannot be revoked. Once set, this command cannot be revoked.
.TP .TP
\fB\-early_stdio_test\fR "on"|"off" \fB\-early_stdio_test\fR "on"|"appendable_wo"|"off"
If enabled by "on" then regular files and block devices get tested for If enabled by "on" then regular files and block devices get tested for
effective access permissions. This implies to try opening those files for effective access permissions. This implies to try opening those files for
writing, which otherwise will happen only later and only if actual writing, which otherwise will happen only later and only if actual
@ -882,6 +882,9 @@ writing is desired.
The test result is used for classifying the pseudo drives as overwriteable, The test result is used for classifying the pseudo drives as overwriteable,
read-only, write-only, or uselessly empty. This may lead to earlier detection read-only, write-only, or uselessly empty. This may lead to earlier detection
of severe problems, and may avoid some less severe error events. of severe problems, and may avoid some less severe error events.
.br
Mode "appendable_wo" is like "on" with the additional property that
non-empty write-only files are regarded as appendable rather than blank.
.TP .TP
.B Inserting files into ISO image: .B Inserting files into ISO image:
.PP .PP

View File

@ -824,7 +824,7 @@ activate them only after image loading.
to write the result into files of nearly arbitrary type. Once to write the result into files of nearly arbitrary type. Once
set, this command cannot be revoked. set, this command cannot be revoked.
-early_stdio_test "on"|"off" -early_stdio_test "on"|"appendable_wo"|"off"
If enabled by "on" then regular files and block devices get tested If enabled by "on" then regular files and block devices get tested
for effective access permissions. This implies to try opening for effective access permissions. This implies to try opening
those files for writing, which otherwise will happen only later those files for writing, which otherwise will happen only later
@ -833,6 +833,9 @@ activate them only after image loading.
overwriteable, read-only, write-only, or uselessly empty. This may overwriteable, read-only, write-only, or uselessly empty. This may
lead to earlier detection of severe problems, and may avoid some lead to earlier detection of severe problems, and may avoid some
less severe error events. less severe error events.
Mode "appendable_wo" is like "on" with the additional property that
non-empty write-only files are regarded as appendable rather than
blank.
 
File: xorriso.info, Node: Insert, Next: SetInsert, Prev: Loading, Up: Options File: xorriso.info, Node: Insert, Next: SetInsert, Prev: Loading, Up: Options
@ -4549,46 +4552,46 @@ Node: Dialog21570
Node: Options23227 Node: Options23227
Node: AqDrive24835 Node: AqDrive24835
Node: Loading27741 Node: Loading27741
Node: Insert41888 Node: Insert42060
Node: SetInsert51507 Node: SetInsert51679
Node: Manip60074 Node: Manip60246
Node: CmdFind68755 Node: CmdFind68927
Node: Filter80055 Node: Filter80227
Node: Writing84404 Node: Writing84576
Node: SetWrite90693 Node: SetWrite90865
Node: Bootable104634 Node: Bootable104806
Node: Jigdo117952 Node: Jigdo118124
Node: Charset122210 Node: Charset122382
Node: Exception124961 Node: Exception125133
Node: DialogCtl129472 Node: DialogCtl129644
Node: Inquiry132059 Node: Inquiry132231
Node: Navigate136436 Node: Navigate136608
Node: Verify144376 Node: Verify144548
Node: Restore152965 Node: Restore153137
Node: Emulation159621 Node: Emulation159793
Node: Scripting169457 Node: Scripting169629
Node: Frontend175019 Node: Frontend175191
Node: Examples176314 Node: Examples176486
Node: ExDevices177483 Node: ExDevices177655
Node: ExCreate178117 Node: ExCreate178289
Node: ExDialog179391 Node: ExDialog179563
Node: ExGrowing180653 Node: ExGrowing180825
Node: ExModifying181455 Node: ExModifying181627
Node: ExBootable181956 Node: ExBootable182128
Node: ExCharset182503 Node: ExCharset182675
Node: ExPseudo183331 Node: ExPseudo183503
Node: ExCdrecord184225 Node: ExCdrecord184397
Node: ExMkisofs184540 Node: ExMkisofs184712
Node: ExGrowisofs185876 Node: ExGrowisofs186048
Node: ExException187000 Node: ExException187172
Node: ExTime187454 Node: ExTime187626
Node: ExIncBackup187913 Node: ExIncBackup188085
Node: ExRestore191834 Node: ExRestore192006
Node: ExRecovery192803 Node: ExRecovery192975
Node: Files193369 Node: Files193541
Node: Seealso194597 Node: Seealso194769
Node: Legal195177 Node: Legal195349
Node: CommandIdx196099 Node: CommandIdx196271
Node: ConceptIdx210479 Node: ConceptIdx210651
 
End Tag Table End Tag Table

View File

@ -44,7 +44,7 @@
@c man .\" First parameter, NAME, should be all caps @c man .\" First parameter, NAME, should be all caps
@c man .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection @c man .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
@c man .\" other parameters are allowed: see man(7), man(1) @c man .\" other parameters are allowed: see man(7), man(1)
@c man .TH XORRISO 1 "Mar 09, 2011" @c man .TH XORRISO 1 "Mar 21, 2011"
@c man .\" Please adjust this date whenever revising the manpage. @c man .\" Please adjust this date whenever revising the manpage.
@c man .\" @c man .\"
@c man .\" Some roff macros, for reference: @c man .\" Some roff macros, for reference:
@ -1097,7 +1097,7 @@ Allow for writing only the usage of MMC optical drives. Disallow
to write the result into files of nearly arbitrary type. to write the result into files of nearly arbitrary type.
Once set, this command cannot be revoked. Once set, this command cannot be revoked.
@c man .TP @c man .TP
@item -early_stdio_test "on"|"off" @item -early_stdio_test "on"|"appendable_wo"|"off"
@kindex -early_stdio_test classifies stdio drives @kindex -early_stdio_test classifies stdio drives
@cindex Drive, classify stdio, -early_stdio_test @cindex Drive, classify stdio, -early_stdio_test
If enabled by "on" then regular files and block devices get tested for If enabled by "on" then regular files and block devices get tested for
@ -1108,6 +1108,9 @@ writing is desired.
The test result is used for classifying the pseudo drives as overwriteable, The test result is used for classifying the pseudo drives as overwriteable,
read-only, write-only, or uselessly empty. This may lead to earlier detection read-only, write-only, or uselessly empty. This may lead to earlier detection
of severe problems, and may avoid some less severe error events. of severe problems, and may avoid some less severe error events.
@*
Mode "appendable_wo" is like "on" with the additional property that
non-empty write-only files are regarded as appendable rather than blank.
@end table @end table
@c man .TP @c man .TP
@c man .B Inserting files into ISO image: @c man .B Inserting files into ISO image:

View File

@ -256,6 +256,11 @@ struct XorrisO { /* the global context of xorriso */
read-write resp. read-only resp. write only. read-write resp. read-only resp. write only.
bit2= Classify files which cannot be opened at all bit2= Classify files which cannot be opened at all
as role 0 : useless dummy. as role 0 : useless dummy.
bit3= Classify non-empty role 5 drives as
BURN_DISC_APPENDABLE with NWA after the
end of the file. It is nevertheless
possible to change this address by call
burn_write_opts_set_start_byte().
*/ */
int do_calm_drive; /* bit0= calm down drive after aquiring it */ int do_calm_drive; /* bit0= calm down drive after aquiring it */

View File

@ -1 +1 @@
#define Xorriso_timestamP "2011.03.21.113858" #define Xorriso_timestamP "2011.03.21.165533"