diff options
author | David Barksdale <amatus@amatus.name> | 2013-09-28 15:20:54 -0500 |
---|---|---|
committer | David Barksdale <amatus@amatus.name> | 2013-09-28 15:20:54 -0500 |
commit | 27cf80b860b7efb53480731e921307457a982e7f (patch) | |
tree | 678c774a44d52c4a90eb0d21ab45560ce1a11c44 /oss.rs | |
parent | 91f8e289c7ed3df1339848f2de9f07d33b35902a (diff) |
Use correct type for read()'s 3rd argument.
Diffstat (limited to 'oss.rs')
-rw-r--r-- | oss.rs | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1,4 +1,4 @@ -use std::libc::{c_int, c_void, close, O_RDONLY, open, read}; +use std::libc::{c_int, c_void, close, O_RDONLY, open, read, size_t}; use std::rt::io::{io_error, IoError, OtherIoError}; use std::vec; @@ -120,7 +120,7 @@ impl OssDevice { unsafe { let length = read(self.fd, vec::raw::to_mut_ptr(buffer) as *mut c_void, - block_size as u32); + block_size as size_t); if length == -1 { break; } |