Introduced builtin filters --zisofs and --zisofs-decode

This commit is contained in:
Thomas Schmitt 2009-04-10 10:32:53 +00:00
parent 25bf8fc5cb
commit 8007b3ae8d
2 changed files with 18 additions and 3 deletions

View File

@ -1 +1 @@
#define Xorriso_timestamP "2009.04.10.102558" #define Xorriso_timestamP "2009.04.10.103130"

View File

@ -9880,8 +9880,8 @@ ex:;
int Xorriso_set_filter(struct XorrisO *xorriso, void *in_node, int Xorriso_set_filter(struct XorrisO *xorriso, void *in_node,
char *path, char *filter_name, int flag) char *path, char *filter_name, int flag)
{ {
int ret, strip_suffix= 0, strip_filter= 0, filter_ret; int ret, strip_suffix= 0, strip_filter= 0, filter_ret= 0;
int explicit_suffix= 0; int explicit_suffix= 0, internal_filter= 0;
IsoNode *node; IsoNode *node;
IsoFile *file; IsoFile *file;
struct Xorriso_lsT *found_lst; struct Xorriso_lsT *found_lst;
@ -9915,6 +9915,10 @@ int Xorriso_set_filter(struct XorrisO *xorriso, void *in_node,
suffix= filter_name + 21; suffix= filter_name + 21;
explicit_suffix= 1; explicit_suffix= 1;
} }
} else if(strcmp(filter_name, "--zisofs") == 0) {
internal_filter= 1;
} else if(strcmp(filter_name, "--zisofs-decode") == 0) {
internal_filter= 2;
} else { } else {
ret= Xorriso_lookup_extf(xorriso, filter_name, &found_lst, 0); ret= Xorriso_lookup_extf(xorriso, filter_name, &found_lst, 0);
if(ret < 0) if(ret < 0)
@ -9966,6 +9970,13 @@ int Xorriso_set_filter(struct XorrisO *xorriso, void *in_node,
break; break;
} }
filter_ret= 1; filter_ret= 1;
} else if (internal_filter == 1 || internal_filter == 2) {
filter_ret = iso_file_add_zisofs_filter(file, internal_filter & 2);
if(filter_ret < 0) {
Xorriso_process_msg_queues(xorriso,0);
Xorriso_report_iso_error(xorriso, "", filter_ret,
"Error when setting filter to ISO node", 0, "FAILURE", 1);
}
} else { } else {
#ifndef Xorriso_allow_extf_suiD #ifndef Xorriso_allow_extf_suiD
@ -10237,6 +10248,10 @@ int Xorriso_stream_type(struct XorrisO *xorriso, IsoNode *node,
strcpy(type_text, "image"); strcpy(type_text, "image");
else else
strcpy(type_text, "disk"); strcpy(type_text, "disk");
} else if(strcmp(text, "ziso") == 0) {
strcpy(type_text, "--zisofs");
} else if(strcmp(text, "osiz") == 0) {
strcpy(type_text, "--zisofs-decode");
} else if(strcmp(text, "cout") == 0 || strcmp(text, "boot") == 0 || } else if(strcmp(text, "cout") == 0 || strcmp(text, "boot") == 0 ||
strcmp(text, "user") == 0 || strcmp(text, "extf") == 0) { strcmp(text, "user") == 0 || strcmp(text, "extf") == 0) {
strcpy(type_text, text); strcpy(type_text, text);