summaryrefslogtreecommitdiff
path: root/ssh-dss.c
diff options
context:
space:
mode:
Diffstat (limited to 'ssh-dss.c')
-rw-r--r--ssh-dss.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/ssh-dss.c b/ssh-dss.c
index dbf8465ba..0215f1c9a 100644
--- a/ssh-dss.c
+++ b/ssh-dss.c
@@ -23,7 +23,7 @@
23 */ 23 */
24 24
25#include "includes.h" 25#include "includes.h"
26RCSID("$OpenBSD: ssh-dss.c,v 1.15 2002/06/23 03:30:17 deraadt Exp $"); 26RCSID("$OpenBSD: ssh-dss.c,v 1.16 2002/07/04 04:15:33 deraadt Exp $");
27 27
28#include <openssl/bn.h> 28#include <openssl/bn.h>
29#include <openssl/evp.h> 29#include <openssl/evp.h>
@@ -85,6 +85,8 @@ ssh_dss_sign(Key *key, u_char **sigp, u_int *lenp,
85 *lenp = SIGBLOB_LEN; 85 *lenp = SIGBLOB_LEN;
86 if (sigp != NULL) 86 if (sigp != NULL)
87 *sigp = ret; 87 *sigp = ret;
88 else
89 xfree(ret);
88 } else { 90 } else {
89 /* ietf-drafts */ 91 /* ietf-drafts */
90 buffer_init(&b); 92 buffer_init(&b);
@@ -98,6 +100,8 @@ ssh_dss_sign(Key *key, u_char **sigp, u_int *lenp,
98 *lenp = len; 100 *lenp = len;
99 if (sigp != NULL) 101 if (sigp != NULL)
100 *sigp = ret; 102 *sigp = ret;
103 else
104 xfree(ret);
101 } 105 }
102 return 0; 106 return 0;
103} 107}