From c51b6298f6e24a154dc73dee375ce96b8edcd147 Mon Sep 17 00:00:00 2001 From: Christophe Grenier Date: Sun, 3 Apr 2011 17:48:27 +0200 Subject: [PATCH] PhotoRec: distinguish Apple .acc from .mp4 --- src/file_mov.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/file_mov.c b/src/file_mov.c index 7d75207a..b072018e 100644 --- a/src/file_mov.c +++ b/src/file_mov.c @@ -124,7 +124,6 @@ static int header_check_mov(const unsigned char *buffer, const unsigned int buff td_memmem(&buffer[i+8], search_size-8, "mp41", 4)!=NULL || td_memmem(&buffer[i+8], search_size-8, "mp42", 4)!=NULL || td_memmem(&buffer[i+8], search_size-8, "mmp4", 4)!=NULL || - td_memmem(&buffer[i+8], search_size-8, "M4A", 3)!=NULL || td_memmem(&buffer[i+8], search_size-8, "M4B", 3)!=NULL || td_memmem(&buffer[i+8], search_size-8, "M4P", 3)!=NULL) { @@ -135,6 +134,15 @@ static int header_check_mov(const unsigned char *buffer, const unsigned int buff file_recovery_new->calculated_file_size=i+atom_size; return 1; } + else if(td_memmem(&buffer[i+8], search_size-8, "M4A", 3)!=NULL) + { + reset_file_recovery(file_recovery_new); + file_recovery_new->extension="acc"; + file_recovery_new->data_check=data_check_mov; + file_recovery_new->file_check=&file_check_size; + file_recovery_new->calculated_file_size=i+atom_size; + return 1; + } else if(td_memmem(&buffer[i+8], search_size-8, "3gp", 3)!=NULL) { reset_file_recovery(file_recovery_new);