pki: Fix ecdsa key dup.

This commit is contained in:
Andreas Schneider
2011-12-29 11:04:00 +01:00
parent fc8a182823
commit ecbdc589f4

View File

@@ -348,6 +348,8 @@ ssh_key pki_key_dup(const ssh_key key, int demote)
const EC_POINT *p;
int ok;
new->ecdsa_nid = key->ecdsa_nid;
new->ecdsa = EC_KEY_new_by_curve_name(key->ecdsa_nid);
if (new->ecdsa == NULL) {
goto fail;