diff options
author | djm@openbsd.org <djm@openbsd.org> | 2017-05-01 22:09:48 +0000 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2017-05-02 13:39:36 +1000 |
commit | d1c6b7fdbdfe4a7a37ecd48a97f0796b061c2868 (patch) | |
tree | 24ca5e459bd32011d59cc57d2056036b3c610e53 /bitmap.c | |
parent | 0f163983016c2988a92e039d18a7569f9ea8e071 (diff) |
upstream commit
when freeing a bitmap, zero all it bytes; spotted by Ilya
Kaliman
Upstream-ID: 834ac024f2c82389d6ea6b1c7d6701b3836e28e4
Diffstat (limited to 'bitmap.c')
-rw-r--r-- | bitmap.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -53,8 +53,9 @@ void bitmap_free(struct bitmap *b) { if (b != NULL && b->d != NULL) { - explicit_bzero(b->d, b->len); + bitmap_zero(b); free(b->d); + b->d = NULL; } free(b); } |