projects
/
pspp
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1ee2c54
)
categoricals: Fix memory leak allocating long string categoricals.
author
Ben Pfaff
<blp@cs.stanford.edu>
Sun, 21 Jul 2019 17:07:15 +0000
(10:07 -0700)
committer
Ben Pfaff
<blp@cs.stanford.edu>
Sun, 21 Jul 2019 18:27:43 +0000
(11:27 -0700)
src/math/categoricals.c
patch
|
blob
|
history
diff --git
a/src/math/categoricals.c
b/src/math/categoricals.c
index 3f9dc0097539eb5b72137866bab815e70e5d99f1..eb28cb42bf50c5601f057c7b7930db63ff2aa9f2 100644
(file)
--- a/
src/math/categoricals.c
+++ b/
src/math/categoricals.c
@@
-383,7
+383,7
@@
categoricals_update (struct categoricals *cat, const struct ccase *c)
{
valn = pool_malloc (cat->pool, sizeof *valn);
valn->index = -1;
- value_init
(
&valn->val, width);
+ value_init
_pool (cat->pool,
&valn->val, width);
value_copy (&valn->val, val, width);
hmap_insert (&vn->valmap, &valn->node, hash);
}