summaryrefslogtreecommitdiff
path: root/mailbox
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2007-07-01 12:59:44 +0000
committerSergey Poznyakoff <gray@gnu.org.ua>2007-07-01 12:59:44 +0000
commit92b3033c2c969e3499425a4159aaee1b13bb40a2 (patch)
tree3ede3db734167e798408e2caa2195883a30e5eb7 /mailbox
parentccb7ad7f2f7ff72086e89a5ecb79c732d718eb58 (diff)
downloadmailutils-92b3033c2c969e3499425a4159aaee1b13bb40a2.tar.gz
mailutils-92b3033c2c969e3499425a4159aaee1b13bb40a2.tar.bz2
(assoc_rehash): Fix an incorrect element size calculation.
Diffstat (limited to 'mailbox')
-rw-r--r--mailbox/assoc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mailbox/assoc.c b/mailbox/assoc.c
index b20d06ffc..8c18de931 100644
--- a/mailbox/assoc.c
+++ b/mailbox/assoc.c
@@ -97,7 +97,7 @@ assoc_rehash (mu_assoc_t assoc)
if (hash_num >= max_rehash)
return MU_ERR_BUFSPACE;
- new_tab = calloc (hash_size[hash_num], assoc->elsize);
+ new_tab = calloc (hash_size[hash_num], ASSOC_ELEM_SIZE (assoc));
assoc->tab = new_tab;
if (old_tab)
{
@@ -114,7 +114,7 @@ assoc_rehash (mu_assoc_t assoc)
if (rc)
return rc;
newp->name = elt->name;
- memcpy(newp->data, elt->data, assoc->elsize);;
+ memcpy(newp->data, elt->data, assoc->elsize);
}
}
free (old_tab);

Return to:

Send suggestions and report system problems to the System administrator.