diff ecdsa.c @ 855:04ede40a529a

- Some fixes for old compilers like tru64 v4 from Daniel Richard G. - Don't warn about blocking random device for prngd
author Matt Johnston <matt@ucc.asn.au>
date Thu, 14 Nov 2013 21:36:45 +0800
parents 7540c0822374
children c19acba28590
line wrap: on
line diff
--- a/ecdsa.c	Thu Nov 14 20:45:46 2013 +0800
+++ b/ecdsa.c	Thu Nov 14 21:36:45 2013 +0800
@@ -36,6 +36,7 @@
 
 ecc_key *gen_ecdsa_priv_key(unsigned int bit_size) {
 	const ltc_ecc_set_type *dp = NULL; // curve domain parameters
+	ecc_key *new_key = NULL;
 	switch (bit_size) {
 #ifdef DROPBEAR_ECC_256
 		case 256:
@@ -67,7 +68,7 @@
 			, bit_size);
 	}
 
-	ecc_key *new_key = m_malloc(sizeof(*new_key));
+	new_key = m_malloc(sizeof(*new_key));
 	if (ecc_make_key_ex(NULL, dropbear_ltc_prng, new_key, dp) != CRYPT_OK) {
 		dropbear_exit("ECC error");
 	}