summaryrefslogtreecommitdiff
path: root/authfd.c
diff options
context:
space:
mode:
authormarkus@openbsd.org <markus@openbsd.org>2015-03-26 19:32:19 +0000
committerDamien Miller <djm@mindrot.org>2015-03-27 12:02:38 +1100
commitfecede00a76fbb33a349f5121c0b2f9fbc04a777 (patch)
tree7daed3709d095d068ba54f33a1eb5949d858b14f /authfd.c
parent1b0ef3813244c78669e6d4d54c624f600945327d (diff)
upstream commit
sigp and lenp are not optional in ssh_agent_sign(); ok djm@
Diffstat (limited to 'authfd.c')
-rw-r--r--authfd.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/authfd.c b/authfd.c
index 9ed5d2f1..82915a43 100644
--- a/authfd.c
+++ b/authfd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: authfd.c,v 1.96 2015/03/25 19:21:48 markus Exp $ */
+/* $OpenBSD: authfd.c,v 1.97 2015/03/26 19:32:19 markus Exp $ */
/*
* Author: Tatu Ylonen <ylo@cs.hut.fi>
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -438,10 +438,8 @@ ssh_agent_sign(int sock, struct sshkey *key,
u_int flags = 0;
int r = SSH_ERR_INTERNAL_ERROR;
- if (sigp != NULL)
- *sigp = NULL;
- if (lenp != NULL)
- *lenp = 0;
+ *sigp = NULL;
+ *lenp = 0;
if (datalen > SSH_KEY_MAX_SIGN_DATA_SIZE)
return SSH_ERR_INVALID_ARGUMENT;
@@ -469,8 +467,7 @@ ssh_agent_sign(int sock, struct sshkey *key,
}
if ((r = sshbuf_get_string(msg, sigp, &len)) != 0)
goto out;
- if (lenp != NULL)
- *lenp = len;
+ *lenp = len;
r = 0;
out:
if (blob != NULL) {