[openssh-commits] [openssh] 01/02: upstream: Set linesize returned by getline to zero when freeing and
git+noreply at mindrot.org
git+noreply at mindrot.org
Mon Feb 1 09:57:38 AEDT 2021
This is an automated email from the git hooks/post-receive script.
djm pushed a commit to branch master
in repository openssh.
commit 7a92a324a2e351fabd0ba8ef9b434d3b12d54ee3
Author: dtucker at openbsd.org <dtucker at openbsd.org>
Date: Sun Jan 31 10:50:10 2021 +0000
upstream: Set linesize returned by getline to zero when freeing and
NULLing the returned string. OpenBSD's getline handles this just fine, but
some implementations used by -portable do not. ok djm@
OpenBSD-Commit-ID: 4d7bd5169d3397654247db9655cc69a9908d165c
---
sshsig.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/sshsig.c b/sshsig.c
index 0b220305..4ce4674c 100644
--- a/sshsig.c
+++ b/sshsig.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sshsig.c,v 1.19 2021/01/26 00:49:30 djm Exp $ */
+/* $OpenBSD: sshsig.c,v 1.20 2021/01/31 10:50:10 dtucker Exp $ */
/*
* Copyright (c) 2019 Google LLC
*
@@ -853,6 +853,7 @@ sshsig_check_allowed_keys(const char *path, const struct sshkey *sign_key,
principal, sig_namespace);
free(line);
line = NULL;
+ linesize = 0;
if (r == SSH_ERR_KEY_NOT_FOUND)
continue;
else if (r == 0) {
@@ -998,6 +999,7 @@ sshsig_find_principals(const char *path, const struct sshkey *sign_key,
sign_key, principals);
free(line);
line = NULL;
+ linesize = 0;
if (r == SSH_ERR_KEY_NOT_FOUND)
continue;
else if (r == 0) {
--
To stop receiving notification emails like this one, please contact
djm at mindrot.org.
More information about the openssh-commits
mailing list