chiark
/
gitweb
/
~mdw
/
mLib
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
@@@ fltfmt mess
[mLib]
/
struct
/
hash.c
diff --git
a/struct/hash.c
b/struct/hash.c
index d4df9b7ce074882b2a1b45e5bcdf2496d210c174..de0ab2bcb09384c8216fe5052b315905a58431a5 100644
(file)
--- a/
struct/hash.c
+++ b/
struct/hash.c
@@
-56,7
+56,7
@@
void hash_create(hash_table *t, size_t n)
hash_base **v;
t->a = arena_global;
hash_base **v;
t->a = arena_global;
-
t->v = x_alloc(t->a, n * sizeof(hash_base *)
);
+
X_NEWV(t->v, t->a, n
);
t->mask = n - 1;
for (v = t->v; n; v++, n--)
*v = 0;
t->mask = n - 1;
for (v = t->v; n; v++, n--)
*v = 0;