git-svn: trunk@4228
remotes/push_mirror/0.95
aCaB 17 years ago
parent 51d1895aef
commit b346e3629a
  1. 5
      ChangeLog
  2. BIN
      contrib/test/clam.bz2.zip
  3. 15
      libclamav/unzip.c
  4. BIN
      test/.split/split.clam.bz2.zipaa
  5. BIN
      test/.split/split.clam.bz2.zipab
  6. 2
      test/Makefile.am
  7. 2
      test/Makefile.in

@ -1,3 +1,8 @@
Tue Oct 7 13:21:04 CEST 2008 (acab)
------------------------------------
* libclamav/unzip.c: error path fixes, handle bzip2's deflate in a special manner - bb#1220
* test: add clam.bz2.zip
Fri Oct 3 19:28:18 CEST 2008 (acab)
------------------------------------
* clamav-milter/clamav-milter.c: properly close descriptors before

Binary file not shown.

@ -174,7 +174,8 @@ static int unz(uint8_t *src, uint32_t csize, uint32_t usize, uint16_t method, ui
if(cli_writen(of, obuf, sizeof(obuf)-(*avail_out)) != (int)(sizeof(obuf)-(*avail_out))) {
cli_warnmsg("cli_unzip: falied to write %lu inflated bytes\n", sizeof(obuf)-(*avail_out));
ret = CL_EIO;
res=1;
res = 100;
break;
}
*next_out = obuf;
*avail_out = sizeof(obuf);
@ -217,18 +218,17 @@ static int unz(uint8_t *src, uint32_t csize, uint32_t usize, uint16_t method, ui
if(cli_writen(of, obuf, sizeof(obuf)-strm.avail_out) != (int)(sizeof(obuf)-strm.avail_out)) {
cli_warnmsg("cli_unzip: falied to write %lu bunzipped bytes\n", sizeof(obuf)-strm.avail_out);
ret = CL_EIO;
res=1;
res = 100;
break;
}
strm.next_out = obuf;
strm.avail_out = sizeof(obuf);
continue;
if (res == BZ_OK) continue; /* after returning BZ_STREAM_END once, decompress returns an error */
}
break;
}
BZ2_bzDecompressEnd(&strm);
if (res == BZ_STREAM_END) {
res=0;
}
if (res == BZ_STREAM_END) res=0;
break;
}
#endif /* HAVE_BZLIB_H */
@ -255,7 +255,8 @@ static int unz(uint8_t *src, uint32_t csize, uint32_t usize, uint16_t method, ui
if(cli_writen(of, obuf, sizeof(obuf)-strm.avail_out) != (int)(sizeof(obuf)-strm.avail_out)) {
cli_warnmsg("cli_unzip: falied to write %lu exploded bytes\n", sizeof(obuf)-strm.avail_out);
ret = CL_EIO;
res=1;
res = 100;
break;
}
strm.next_out = (uint8_t *)obuf;
strm.avail_out = sizeof(obuf);

Binary file not shown.

Binary file not shown.

@ -4,7 +4,7 @@ FILES = clam-v2.rar clam-v3.rar clam.cab clam.exe.bz2 clam.exe clam.zip \
clam-nsis.exe clam-petite.exe clam-upack.exe clam-wwpack.exe clam.pdf\
clam.mail clam.ppt clam.tnef clam.ea05.exe clam.ea06.exe clam.d64.zip\
clam.exe.mbox.base64 clam.exe.mbox.uu clam.exe.binhex clam.ole.doc \
clam.impl.zip clam.exe.html
clam.impl.zip clam.exe.html clam.bz2.zip
SPLIT_DIR=$(top_srcdir)/test/.split

@ -198,7 +198,7 @@ FILES = clam-v2.rar clam-v3.rar clam.cab clam.exe.bz2 clam.exe clam.zip \
clam-nsis.exe clam-petite.exe clam-upack.exe clam-wwpack.exe clam.pdf\
clam.mail clam.ppt clam.tnef clam.ea05.exe clam.ea06.exe clam.d64.zip\
clam.exe.mbox.base64 clam.exe.mbox.uu clam.exe.binhex clam.ole.doc \
clam.impl.zip clam.exe.html
clam.impl.zip clam.exe.html clam.bz2.zip
SPLIT_DIR = $(top_srcdir)/test/.split
EXTRA_DIST = .split

Loading…
Cancel
Save