Fix no_std issue with new error types.

This commit is contained in:
Isis Lovecruft 2020-07-16 23:18:00 +00:00
parent d3a5b3bd81
commit 5458ebef88
No known key found for this signature in database
GPG key ID: AB41313533E8E812

View file

@ -466,7 +466,7 @@ impl ExpandedSecretKey {
let ctx: &[u8] = context.unwrap_or(b""); // By default, the context is an empty string.
if ctx.len() > 255 {
return Err(SignatureError::from_source(InternalError::PrehashedContextLengthError));
return Err(SignatureError::from(InternalError::PrehashedContextLengthError));
}
let ctx_len: u8 = ctx.len() as u8;