summaryrefslogtreecommitdiffstats
path: root/src/file_fcs.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2015-05-11 09:25:39 +0200
committerChristophe Grenier <grenier@cgsecurity.org>2015-05-11 09:25:39 +0200
commite1ca4010307fb53d83c5036f6c8269eb9066c928 (patch)
tree79a9547954c70be7ddc88324990d60a163ffb16d /src/file_fcs.c
parentf63304053aa32515e4853c2472fb785bcda0307c (diff)
remove always-true memcmp
Diffstat (limited to 'src/file_fcs.c')
-rw-r--r--src/file_fcs.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/file_fcs.c b/src/file_fcs.c
index fded067..40d090a 100644
--- a/src/file_fcs.c
+++ b/src/file_fcs.c
@@ -124,10 +124,10 @@ static int header_check_fcs(const unsigned char *buffer, const unsigned int buff
if(i+1+8+1<text_end &&
memcmp(buffer+i+1,"$ENDDATA",8)==0 && buffer[i+1+8]==delimiter)
data_end=ascii2int2(&buffer[i+1+8+1], text_end-(i+1+8+1), delimiter);
- else if(i+1+9+1<text_end &&
+ else if(i+1+9+1<text_end &&
memcmp(buffer+i+1,"$ENDSTEXT",9)==0 && buffer[i+1+9]==delimiter)
stext_end=ascii2int2(&buffer[i+1+9+1], text_end-(i+1+9+1), delimiter);
- else if(i+1+12+1<text_end &&
+ else if(i+1+12+1<text_end &&
memcmp(buffer+i+1,"$ENDANALYSIS",12)==0 && buffer[i+1+12]==delimiter)
analysis_end=ascii2int2(&buffer[i+1+12+1], text_end-(i+1+12+1), delimiter);
}