From 57dd3233e47369aa32288eeb4d408c2169e82eb0 Mon Sep 17 00:00:00 2001 From: djm Date: Mon, 1 May 2017 22:09:48 +0000 Subject: [PATCH] when freeing a bitmap, zero all it bytes; spotted by Ilya Kaliman --- usr.bin/ssh/bitmap.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/usr.bin/ssh/bitmap.c b/usr.bin/ssh/bitmap.c index b9df2c9f303..776a01e5917 100644 --- a/usr.bin/ssh/bitmap.c +++ b/usr.bin/ssh/bitmap.c @@ -51,8 +51,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); } -- 2.20.1