Rejected unsuitable addresses "stdio:" , "stdio:/", "stdio:-", "stdio:."

This commit is contained in:
Thomas Schmitt 2008-01-21 22:21:01 +00:00
parent 0b8358911e
commit 8da7ffc314
3 changed files with 17 additions and 8 deletions

View File

@ -2,7 +2,7 @@
.\" First parameter, NAME, should be all caps
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
.\" other parameters are allowed: see man(7), man(1)
.TH XORRISO 1 "January 2, 2008"
.TH XORRISO 1 "January 21, 2008"
.\" Please adjust this date whenever revising the manpage.
.\"
.\" Some roff macros, for reference:

View File

@ -6597,13 +6597,22 @@ int Xorriso_option_dev(struct XorrisO *xorriso, char *in_adr, int flag)
adr= in_adr;
if(strcmp(in_adr, "-")==0)
adr= "stdio:/dev/fd/1";
if(xorriso->ban_stdio_write && strncmp(adr, "stdio:", 6)==0) {
if(strncmp(adr, "stdio:", 6)==0) {
if(strlen(adr)==6 || strcmp(adr, "stdio:/")==0 ||
strcmp(adr, "stdio:.")==0 || strcmp(adr, "stdio:..")==0 ||
strcmp(adr, "stdio:-")==0) {
sprintf(xorriso->info_text,
"Drive address banned by -ban_stdio_write : '%s'",
adr);
"No suitable path given by device address '%s'", adr);
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "SORRY", 0);
return(0);
}
if(xorriso->ban_stdio_write) {
sprintf(xorriso->info_text,
"Drive address banned by -ban_stdio_write : '%s'", adr);
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "SORRY", 0);
return(0);
}
}
if(xorriso->volset_change_pending && (flag&1)) {
sprintf(xorriso->info_text,

View File

@ -1 +1 @@
#define Xorriso_timestamP "2008.01.20.200254"
#define Xorriso_timestamP "2008.01.21.221939"