aboutsummaryrefslogtreecommitdiff
path: root/crypto/hmac.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/hmac.rs')
-rw-r--r--crypto/hmac.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crypto/hmac.rs b/crypto/hmac.rs
index d7a76e08..2056dc09 100644
--- a/crypto/hmac.rs
+++ b/crypto/hmac.rs
@@ -16,7 +16,7 @@
use std::libc::{c_uchar, c_int, c_uint};
use std::ptr;
-use std::vec;
+use std::slice;
use crypto::hash;
#[allow(non_camel_case_types)]
@@ -72,7 +72,7 @@ impl HMAC {
pub fn final(&mut self) -> ~[u8] {
unsafe {
- let mut res = vec::from_elem(self.len, 0u8);
+ let mut res = slice::from_elem(self.len, 0u8);
let mut outlen = 0;
HMAC_Final(&mut self.ctx, res.as_mut_ptr(), &mut outlen);
assert!(self.len == outlen as uint)