Linux fallocate(2) bindings

This commit is contained in:
Dan Burkert 2015-11-03 20:58:44 -08:00
parent c003614b61
commit 0b46775490
2 changed files with 5 additions and 0 deletions

View file

@ -281,6 +281,8 @@ extern {
offset: ::off64_t,
whence: ::c_int) -> ::c_int;
pub fn ftello64(stream: *mut ::FILE) -> ::off64_t;
pub fn fallocate(fd: ::c_int, mode: ::c_int,
offset: ::off_t, len: ::off_t) -> ::c_int;
}
cfg_if! {

View file

@ -179,6 +179,9 @@ pub const SIGCHLD: ::c_int = 17;
pub const SIGBUS: ::c_int = 7;
pub const SIG_SETMASK: ::c_int = 2;
pub const FALLOC_FL_KEEP_SIZE: ::c_int = 0x01;
pub const FALLOC_FL_PUNCH_HOLE: ::c_int = 0x02;
extern {
pub fn getnameinfo(sa: *const ::sockaddr,
salen: ::socklen_t,