[Pkg-clamav-commits] [SCM] Debian repository for ClamAV branch, debian/unstable, updated. debian/0.95+dfsg-1-6156-g094ec9b
aCaB
acab at clamav.net
Sun Apr 4 01:13:36 UTC 2010
The following commit has been merged in the debian/unstable branch:
commit 4ddd73d4dae32ef451cb3dad0ee7e3d21b7e156c
Author: aCaB <acab at clamav.net>
Date: Mon Jan 4 17:21:12 2010 +0100
hashset fixes
diff --git a/libclamav/hashtab.c b/libclamav/hashtab.c
index 62861fb..6066529 100644
--- a/libclamav/hashtab.c
+++ b/libclamav/hashtab.c
@@ -444,6 +444,8 @@ int cli_hashset_init(struct cli_hashset* hs, size_t initial_capacity, uint8_t lo
void cli_hashset_destroy(struct cli_hashset* hs)
{
+ if (!hs->keys)
+ return 0;
cli_dbgmsg(MODULE_NAME "Freeing hashset, elements: %u, capacity: %u\n", hs->count, hs->capacity);
free(hs->keys);
free(hs->bitmap);
diff --git a/libclamav/pe.c b/libclamav/pe.c
index 2b8442f..c274e60 100644
--- a/libclamav/pe.c
+++ b/libclamav/pe.c
@@ -2405,7 +2405,7 @@ int cli_peheader(fmap_t *map, struct cli_exe_info *peinfo)
return -1;
}
- if(cli_hashset_init(&peinfo->vinfo, 32, 80)) {
+ if(cli_hashset_init(peinfo->vinfo, 32, 80)) {
cli_errmsg("Unable to init vinfo hs\n");
free(section_hdr);
free(peinfo->section);
--
Debian repository for ClamAV
More information about the Pkg-clamav-commits
mailing list