summaryrefslogtreecommitdiffstats
path: root/src/file_mpg.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2014-10-05 21:10:05 +0200
committerChristophe Grenier <grenier@cgsecurity.org>2014-10-05 21:10:05 +0200
commitf83141b780f3d6ea62501f7ab1d38ce00d2b9cf2 (patch)
tree1ca518cfd635ce4dccb7f8380255169963c58854 /src/file_mpg.c
parent0ecfeb2d7a2d2a4b5bb315fdd2b3303d300def78 (diff)
PhotoRec: remove useless file_recovery NULL check
Diffstat (limited to 'src/file_mpg.c')
-rw-r--r--src/file_mpg.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/file_mpg.c b/src/file_mpg.c
index d7f1768..20e1fbe 100644
--- a/src/file_mpg.c
+++ b/src/file_mpg.c
@@ -177,7 +177,7 @@ static int header_check_mpg_Pack(const unsigned char *buffer, const unsigned int
file_recovery_new->file_check=&file_check_size;
return 1;
}
- if(file_recovery!=NULL && file_recovery->file_stat!=NULL && file_recovery->file_stat->file_hint==&file_hint_mpg)
+ if(file_recovery->file_stat!=NULL && file_recovery->file_stat->file_hint==&file_hint_mpg)
return 0;
reset_file_recovery(file_recovery_new);
file_recovery_new->extension=file_hint_mpg.extension;
@@ -220,7 +220,7 @@ static int header_check_mpg_Pack(const unsigned char *buffer, const unsigned int
file_recovery_new->file_check=&file_check_size;
return 1;
}
- if(file_recovery!=NULL && file_recovery->file_stat!=NULL && file_recovery->file_stat->file_hint==&file_hint_mpg)
+ if(file_recovery->file_stat!=NULL && file_recovery->file_stat->file_hint==&file_hint_mpg)
return 0;
reset_file_recovery(file_recovery_new);
file_recovery_new->extension=file_hint_mpg.extension;
@@ -235,7 +235,7 @@ static int header_check_mpg_Pack(const unsigned char *buffer, const unsigned int
static int header_check_mpg_System(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)
{
- if(file_recovery!=NULL && file_recovery->file_stat!=NULL && file_recovery->file_stat->file_hint==&file_hint_mpg)
+ if(file_recovery->file_stat!=NULL && file_recovery->file_stat->file_hint==&file_hint_mpg)
return 0;
/* MPEG-1 http://andrewduncan.ws/MPEG/MPEG-1.ps */
/* ISO/IEC INTERNATIONAL 13818-1 STANDARD
@@ -277,7 +277,7 @@ static int header_check_mpg_System(const unsigned char *buffer, const unsigned i
static int header_check_mpg_Sequence(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)
{
- if(file_recovery!=NULL && file_recovery->file_stat!=NULL && file_recovery->file_stat->file_hint==&file_hint_mpg)
+ if(file_recovery->file_stat!=NULL && file_recovery->file_stat->file_hint==&file_hint_mpg)
return 0;
/* MPEG-1 sequence header code 0x1B3 */
/* horizontal size>0 */
@@ -312,7 +312,7 @@ static int header_check_mpg_Sequence(const unsigned char *buffer, const unsigned
static int header_check_mpg4_ElemVideo(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)
{
- if(file_recovery!=NULL && file_recovery->file_stat!=NULL && file_recovery->file_stat->file_hint==&file_hint_mpg)
+ if(file_recovery->file_stat!=NULL && file_recovery->file_stat->file_hint==&file_hint_mpg)
return 0;
/* ISO/IEC 14496-2 (MPEG-4 video) ELEMENTARY VIDEO HEADER - visual object start code */
/* is_visual_object_identifier */