cosmetic patch

git-svn: trunk@1127
remotes/push_mirror/metadata
Tomasz Kojm 21 years ago
parent d17f081e46
commit c40986203d
  1. 5
      clamav-devel/ChangeLog
  2. 14
      clamav-devel/libclamav/scanners.c

@ -1,3 +1,8 @@
Fri Nov 26 22:01:58 CET 2004 (tk)
---------------------------------
* libclamav/scanners.c: cli_scanzip: apply cosmetic patch from Andrey J.
Melnikoff (TEMHOTA) <temnota*kmv.ru>
Fri Nov 26 21:07:19 CET 2004 (tk)
---------------------------------
* libclamav/pe.c: do not trigger a warning on IMAGE_SUBSYSTEM_UNKNOWN

@ -385,6 +385,12 @@ static int cli_scanzip(int desc, const char **virname, long int *scanned, const
}
}
if((zfp = zzip_file_open(zdir, zdirent.d_name, 0)) == NULL) {
cli_dbgmsg("Zip: Can't open file %s\n", zdirent.d_name);
ret = CL_EZIP;
break;
}
/* generate temporary file and get its descriptor */
if((tmp = tmpfile()) == NULL) {
cli_dbgmsg("Zip: Can't generate tmpfile().\n");
@ -392,12 +398,6 @@ static int cli_scanzip(int desc, const char **virname, long int *scanned, const
break;
}
if((zfp = zzip_file_open(zdir, zdirent.d_name, 0)) == NULL) {
cli_dbgmsg("Zip: Can't open file %s\n", zdirent.d_name);
ret = CL_EZIP;
break;
}
while((bytes = zzip_file_read(zfp, buff, FILEBUFF)) > 0) {
if(fwrite(buff, 1, bytes, tmp) != (size_t) bytes) {
cli_dbgmsg("Zip: Can't write to file.\n");
@ -405,7 +405,7 @@ static int cli_scanzip(int desc, const char **virname, long int *scanned, const
zzip_dir_close(zdir);
fclose(tmp);
free(buff);
return CL_EZIP;
return CL_EIO;
}
}

Loading…
Cancel
Save