mirror of
https://github.com/PowerShell/openssh-portable.git
synced 2025-07-23 13:55:13 +02:00
Put EC key export inside OPENSSL_HAS_ECC.
Fixes link error when building against an OpenSSL that does not have ECC.
This commit is contained in:
parent
94a2e5951b
commit
e16dfa94f8
@ -406,10 +406,12 @@ do_convert_to_pem(struct sshkey *k)
|
|||||||
if (!PEM_write_DSA_PUBKEY(stdout, k->dsa))
|
if (!PEM_write_DSA_PUBKEY(stdout, k->dsa))
|
||||||
fatal("PEM_write_DSA_PUBKEY failed");
|
fatal("PEM_write_DSA_PUBKEY failed");
|
||||||
break;
|
break;
|
||||||
|
#ifdef OPENSSL_HAS_ECC
|
||||||
case KEY_ECDSA:
|
case KEY_ECDSA:
|
||||||
if (!PEM_write_EC_PUBKEY(stdout, k->ecdsa))
|
if (!PEM_write_EC_PUBKEY(stdout, k->ecdsa))
|
||||||
fatal("PEM_write_EC_PUBKEY failed");
|
fatal("PEM_write_EC_PUBKEY failed");
|
||||||
break;
|
break;
|
||||||
|
#endif
|
||||||
default:
|
default:
|
||||||
fatal("%s: unsupported key type %s", __func__, sshkey_type(k));
|
fatal("%s: unsupported key type %s", __func__, sshkey_type(k));
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user