Fix the ambiguous integer literal error

This commit fixes this:

> src/crypto/symm.rs:95:25: 95:52 error: cannot determine a type for
> this expression: cannot determine the type of this integer; add a
> suffix to specify the type explicitly [E0101]
> src/crypto/symm.rs:95                 let v = if padding { 1 } else { 0 } as c_int;
This commit is contained in:
Eunchong Yu 2014-08-27 15:40:09 +09:00
parent 07f12370d3
commit 11c44d3b88
1 changed files with 1 additions and 1 deletions

View File

@ -92,7 +92,7 @@ impl Crypter {
pub fn pad(&self, padding: bool) { pub fn pad(&self, padding: bool) {
if self.blocksize > 0 { if self.blocksize > 0 {
unsafe { unsafe {
let v = if padding { 1 } else { 0 } as c_int; let v = if padding { 1 as c_int } else { 0 };
EVP_CIPHER_CTX_set_padding(self.ctx, v); EVP_CIPHER_CTX_set_padding(self.ctx, v);
} }
} }