summaryrefslogtreecommitdiffstats
path: root/src/file_zip.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2015-09-03 08:04:04 +0200
committerChristophe Grenier <grenier@cgsecurity.org>2015-09-03 08:04:04 +0200
commit00557961744f0a88000678db179a84a4a0e4fdfd (patch)
treedb0bae677a788104fa71edaebcbfa30402833179 /src/file_zip.c
parentac980c4a61e0158ce5ceec8555a89b38eac5066c (diff)
PhotoRec: reduce the number of backward search
Diffstat (limited to 'src/file_zip.c')
-rw-r--r--src/file_zip.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/file_zip.c b/src/file_zip.c
index e510013..a831279 100644
--- a/src/file_zip.c
+++ b/src/file_zip.c
@@ -780,13 +780,19 @@ static int header_check_zip(const unsigned char *buffer, const unsigned int buff
(strcmp(file_recovery->extension,"doc")==0 ||
strcmp(file_recovery->extension,"psmodel")==0)
&& memcmp(&buffer[30], "macrolog_1.mac", 14)==0)
+ {
+ header_ignored(file_recovery_new);
return 0;
+ }
/* A zip file begins by ZIP_FILE_ENTRY, this signature can also be
* found for each compressed file */
if(file_recovery->file_stat!=NULL &&
file_recovery->file_stat->file_hint==&file_hint_zip &&
safe_header_only==0)
+ {
+ header_ignored(file_recovery_new);
return 0;
+ }
reset_file_recovery(file_recovery_new);
file_recovery_new->min_filesize=21;
file_recovery_new->file_check=&file_check_zip;