[openssh-commits] [openssh] 01/01: freezero should check for NULL.

git+noreply at mindrot.org git+noreply at mindrot.org
Fri Feb 16 17:34:29 AEDT 2018


This is an automated email from the git hooks/post-receive script.

dtucker pushed a commit to branch master
in repository openssh.

commit f6dc2ba3c9d12be53057b9371f5109ec553a399f
Author: Darren Tucker <dtucker at dtucker.net>
Date:   Fri Feb 16 17:32:28 2018 +1100

    freezero should check for NULL.
---
 openbsd-compat/freezero.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/openbsd-compat/freezero.c b/openbsd-compat/freezero.c
index ca5de785..90b9d381 100644
--- a/openbsd-compat/freezero.c
+++ b/openbsd-compat/freezero.c
@@ -23,6 +23,8 @@
 void
 freezero(void *ptr, size_t sz)
 {
+	if (ptr == NULL)
+		return;
 	explicit_bzero(ptr, sz);
 	free(ptr);
 }

-- 
To stop receiving notification emails like this one, please contact
djm at mindrot.org.


More information about the openssh-commits mailing list