Skip to content

Commit 2a2dde1

Browse files
committed
Try fixing test on i686-unknown-linux-gnu
1 parent b2d404d commit 2a2dde1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tests/run-pass/libc.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55

66
extern crate libc;
77

8+
use std::convert::TryInto;
89
use std::env::temp_dir;
910
use std::fs::{File, remove_file};
1011
use std::io::Write;
@@ -25,7 +26,7 @@ fn main() {
2526
libc::posix_fadvise(
2627
file.as_raw_fd(),
2728
0,
28-
bytes.len() as i64,
29+
bytes.len().try_into().unwrap(),
2930
libc::POSIX_FADV_DONTNEED,
3031
)
3132
};

0 commit comments

Comments
 (0)