summaryrefslogtreecommitdiffstats
path: root/usr.bin/ssh/sshconnect2.c
diff options
context:
space:
mode:
authormarkus <markus@openbsd.org>2016-01-14 22:56:56 +0000
committermarkus <markus@openbsd.org>2016-01-14 22:56:56 +0000
commite52c0427fc4475ce688c22f0f64bf678d9522e1e (patch)
treefabcb8a9fb2ee98035010699af669c1cb7e805dc /usr.bin/ssh/sshconnect2.c
parentCheck the return value of snprintf() for potential overflow instead (diff)
downloadwireguard-openbsd-e52c0427fc4475ce688c22f0f64bf678d9522e1e.tar.xz
wireguard-openbsd-e52c0427fc4475ce688c22f0f64bf678d9522e1e.zip
fd leaks; report Qualys Security Advisory team; ok deraadt@
Diffstat (limited to 'usr.bin/ssh/sshconnect2.c')
-rw-r--r--usr.bin/ssh/sshconnect2.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.bin/ssh/sshconnect2.c b/usr.bin/ssh/sshconnect2.c
index 55c1b49f750..4d65bc0c1dc 100644
--- a/usr.bin/ssh/sshconnect2.c
+++ b/usr.bin/ssh/sshconnect2.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sshconnect2.c,v 1.236 2016/01/14 16:17:40 markus Exp $ */
+/* $OpenBSD: sshconnect2.c,v 1.237 2016/01/14 22:56:56 markus Exp $ */
/*
* Copyright (c) 2000 Markus Friedl. All rights reserved.
* Copyright (c) 2008 Damien Miller. All rights reserved.
@@ -1336,6 +1336,7 @@ pubkey_prepare(Authctxt *authctxt)
if (r != SSH_ERR_AGENT_NO_IDENTITIES)
debug("%s: ssh_fetch_identitylist: %s",
__func__, ssh_err(r));
+ close(agent_fd);
} else {
for (j = 0; j < idlist->nkeys; j++) {
found = 0;