diff --git a/xorriso/xorriso.c b/xorriso/xorriso.c index 63a8ccf1..b6caedc3 100644 --- a/xorriso/xorriso.c +++ b/xorriso/xorriso.c @@ -7346,7 +7346,11 @@ cannot_address:; if(xorriso->do_md5 & 16) { use_md5= 1; - ret= Xorriso_get_md5(xorriso, NULL, iso_adr, iso_md5, 1); + ret= Xorriso_is_plain_image_file(xorriso, NULL, iso_adr, 0); + if(ret <= 0) + ret= 0; /* (reverse) filtered files are likely not to match their MD5 */ + else + ret= Xorriso_get_md5(xorriso, NULL, iso_adr, iso_md5, 1); if(ret <= 0) use_md5= 0; else { diff --git a/xorriso/xorriso_timestamp.h b/xorriso/xorriso_timestamp.h index e79efafa..89ab7ee3 100644 --- a/xorriso/xorriso_timestamp.h +++ b/xorriso/xorriso_timestamp.h @@ -1 +1 @@ -#define Xorriso_timestamP "2009.09.06.144813" +#define Xorriso_timestamP "2009.09.07.161247" diff --git a/xorriso/xorrisoburn.c b/xorriso/xorrisoburn.c index ac56d444..3e7c28bf 100644 --- a/xorriso/xorrisoburn.c +++ b/xorriso/xorrisoburn.c @@ -3625,11 +3625,19 @@ int Xorriso_restore_implicit_properties(struct XorrisO *xorriso, } -int Xorriso_is_plain_image_file(struct XorrisO *xorriso, IsoNode *node, - int flag) +int Xorriso_is_plain_image_file(struct XorrisO *xorriso, void *in_node, + char *path, int flag) { int ret, lba; IsoStream *stream; + IsoNode *node; + + node= (IsoNode *) in_node; + if(node == NULL) { + ret= Xorriso_get_node_by_path(xorriso, path, NULL, &node, 0); + if(ret<=0) + return(ret); + } ret= Xorriso__file_start_lba(node, &lba, 0); if(ret > 0) { /* Stream source is from loaded image */ @@ -3748,7 +3756,7 @@ int Xorriso_tree_restore_node(struct XorrisO *xorriso, IsoNode *node, ret= Xorriso_iso_file_read(xorriso, data_stream, buf, wanted, 0); if(ret<=0) { if(xorriso->extract_error_mode == 0 && - Xorriso_is_plain_image_file(xorriso, node, 0)) { + Xorriso_is_plain_image_file(xorriso, node, "", 0)) { close(write_fd); write_fd= -1; already_done= (size - todo) / (off_t) 2048; @@ -10118,7 +10126,7 @@ int Xorriso_extract_cut(struct XorrisO *xorriso, } read_raw= 0; if((img_offset % 2048) == 0) { - ret= Xorriso_is_plain_image_file(xorriso, node, 0); + ret= Xorriso_is_plain_image_file(xorriso, node, "", 0); if(ret > 0) read_raw= 1; } diff --git a/xorriso/xorrisoburn.h b/xorriso/xorrisoburn.h index cd8322fd..50b28bc5 100644 --- a/xorriso/xorrisoburn.h +++ b/xorriso/xorrisoburn.h @@ -480,6 +480,9 @@ int Xorriso_md5_end(struct XorrisO *xorriso, void **ctx, char md5[16], */ int Xorriso_drive_snooze(struct XorrisO *xorriso, int flag); +int Xorriso_is_plain_image_file(struct XorrisO *xorriso, void *in_node, + char *path, int flag); + /* A pseudo file type for El-Torito bootsectors as in man 2 stat : For now take the highest possible value.