summaryrefslogtreecommitdiffstats
path: root/src/file_fcp.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/file_fcp.c')
-rw-r--r--src/file_fcp.c21
1 files changed, 8 insertions, 13 deletions
diff --git a/src/file_fcp.c b/src/file_fcp.c
index bf825a8..8876c2f 100644
--- a/src/file_fcp.c
+++ b/src/file_fcp.c
@@ -30,7 +30,6 @@
#include "filegen.h"
static void register_header_check_fcp(file_stat_t *file_stat);
-static int header_check_fcp(const unsigned char *buffer, const unsigned int buffer_size, const unsigned int safe_header_only, const file_recovery_t *file_recovery, file_recovery_t *file_recovery_new);
const file_hint_t file_hint_fcp= {
.extension="fcp",
@@ -42,25 +41,21 @@ const file_hint_t file_hint_fcp= {
.register_header_check=&register_header_check_fcp
};
-static const unsigned char fcp_header[5]= { 0xA2, 'K','e','y','G'};
/*
Final Cut Pro is a professional non-linear editing system
developed by Apple Inc.
- Mac Creator code: KeyG
+ Mac Creator code: KeyG
*/
-static void register_header_check_fcp(file_stat_t *file_stat)
+static int header_check_fcp(const unsigned char *buffer, const unsigned int buffer_size, const unsigned int safe_header_only, const file_recovery_t *file_recovery, file_recovery_t *file_recovery_new)
{
- register_header_check(0, fcp_header,sizeof(fcp_header), &header_check_fcp, file_stat);
+ reset_file_recovery(file_recovery_new);
+ file_recovery_new->extension=file_hint_fcp.extension;
+ return 1;
}
-static int header_check_fcp(const unsigned char *buffer, const unsigned int buffer_size, const unsigned int safe_header_only, const file_recovery_t *file_recovery, file_recovery_t *file_recovery_new)
+static void register_header_check_fcp(file_stat_t *file_stat)
{
- if(memcmp(buffer,fcp_header,sizeof(fcp_header))==0)
- {
- reset_file_recovery(file_recovery_new);
- file_recovery_new->extension=file_hint_fcp.extension;
- return 1;
- }
- return 0;
+ static const unsigned char fcp_header[5]= { 0xA2, 'K','e','y','G'};
+ register_header_check(0, fcp_header,sizeof(fcp_header), &header_check_fcp, file_stat);
}