return 1 for other JPEG exploit variants

git-svn: trunk@1002
remotes/push_mirror/metadata
Tomasz Kojm 21 years ago
parent 322bfd0357
commit 1ac8b1a0da
  1. 4
      clamav-devel/ChangeLog
  2. 6
      clamav-devel/libclamav/special.c

@ -1,3 +1,7 @@
Fri Oct 15 02:23:02 CEST 2004 (tk)
----------------------------------
* libclamav/special.c: return 1 for other JPEG exploit variants
Fri Oct 15 01:53:42 CEST 2004 (tk)
----------------------------------
* libclamav/scanners.c: do not return CL_EFORMAT to callers

@ -67,14 +67,14 @@ int cli_check_jpeg_exploit(int fd)
unsigned char buffer[4];
off_t offset;
int retval;
cli_dbgmsg("in cli_check_jpeg_exploit()\n");
if (cli_readn(fd, buffer, 2) != 2) {
return 0;
}
if ((buffer[0] != 0xff) || (buffer[1] != 0xd8)) {
return 0;
}
@ -104,7 +104,7 @@ int cli_check_jpeg_exploit(int fd)
}
offset = ((unsigned int) buffer[2] << 8) + buffer[3];
if (offset < 2) {
return 2;
return 1;
}
offset -= 2;
offset += lseek(fd, 0, SEEK_CUR);

Loading…
Cancel
Save