diff ecdsa.c @ 1000:c0b1b7eb5c84

Fix memory leak of ecdsa structure, found by Coverity
author Matt Johnston <matt@ucc.asn.au>
date Wed, 28 Jan 2015 22:29:18 +0800
parents c19acba28590
children 063c38ea622b
line wrap: on
line diff
--- a/ecdsa.c	Wed Jan 28 22:22:32 2015 +0800
+++ b/ecdsa.c	Wed Jan 28 22:29:18 2015 +0800
@@ -131,6 +131,7 @@
 
 	if (buf_getmpint(buf, new_key->k) != DROPBEAR_SUCCESS) {
 		ecc_free(new_key);
+		m_free(new_key);
 		return NULL;
 	}