Fix missing return in loadPrivateKey

This commit is contained in:
xenolf 2016-02-06 22:41:29 +01:00
parent 1f777a0d77
commit d46b0db199

View file

@ -47,7 +47,7 @@ func loadPrivateKey(file string) (crypto.PrivateKey, error) {
switch keyBlock.Type { switch keyBlock.Type {
case "RSA PRIVATE KEY": case "RSA PRIVATE KEY":
x509.ParsePKCS1PrivateKey(keyBlock.Bytes) return x509.ParsePKCS1PrivateKey(keyBlock.Bytes)
case "EC PRIVATE KEY": case "EC PRIVATE KEY":
return x509.ParseECPrivateKey(keyBlock.Bytes) return x509.ParseECPrivateKey(keyBlock.Bytes)
} }