diff options
| author | Steven Fackler <[email protected]> | 2016-08-07 17:48:18 -0700 |
|---|---|---|
| committer | Steven Fackler <[email protected]> | 2016-08-07 17:48:18 -0700 |
| commit | b56908a3924f68c86ba4a5686c670182ef12c6e4 (patch) | |
| tree | 506d32f209c34919c8810c2e4c9aba33d3ba2e7a /openssl/src | |
| parent | Hash reform (diff) | |
| download | rust-openssl-b56908a3924f68c86ba4a5686c670182ef12c6e4.tar.xz rust-openssl-b56908a3924f68c86ba4a5686c670182ef12c6e4.zip | |
Take a c_ulong directly in BN construction
Closes #416
Diffstat (limited to 'openssl/src')
| -rw-r--r-- | openssl/src/bn/mod.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/openssl/src/bn/mod.rs b/openssl/src/bn/mod.rs index 3a1efb4a..254e674e 100644 --- a/openssl/src/bn/mod.rs +++ b/openssl/src/bn/mod.rs @@ -584,9 +584,9 @@ impl BigNum { } /// Creates a new `BigNum` with the given value. - pub fn new_from(n: u64) -> Result<BigNum, ErrorStack> { + pub fn new_from(n: c_ulong) -> Result<BigNum, ErrorStack> { BigNum::new().and_then(|v| unsafe { - try_ssl!(ffi::BN_set_word(v.raw(), n as c_ulong)); + try_ssl!(ffi::BN_set_word(v.raw(), n)); Ok(v) }) } |