From 684c4574c09a6f2cc5a208e4505e9306602b4abc Mon Sep 17 00:00:00 2001 From: Daniel Mueller Date: Mon, 29 May 2017 14:07:12 -0700 Subject: Update libc crate to 0.2.23 The 'libc' create got a couple of updates. This change imports the new code and bumps the version to use. Import subrepo libc/:libc at 7db3fd570dfb41a38fb17116e93679307178103a --- libc/src/unix/bsd/freebsdlike/mod.rs | 48 +++++++++++++----------------------- 1 file changed, 17 insertions(+), 31 deletions(-) (limited to 'libc/src/unix/bsd/freebsdlike/mod.rs') diff --git a/libc/src/unix/bsd/freebsdlike/mod.rs b/libc/src/unix/bsd/freebsdlike/mod.rs index f9c8dcb..daf3f29 100644 --- a/libc/src/unix/bsd/freebsdlike/mod.rs +++ b/libc/src/unix/bsd/freebsdlike/mod.rs @@ -452,6 +452,11 @@ pub const F_SETFD: ::c_int = 2; pub const F_GETFL: ::c_int = 3; pub const F_SETFL: ::c_int = 4; +pub const AT_EACCESS: ::c_int = 0x100; +pub const AT_SYMLINK_NOFOLLOW: ::c_int = 0x200; +pub const AT_SYMLINK_FOLLOW: ::c_int = 0x400; +pub const AT_REMOVEDIR: ::c_int = 0x800; + pub const SIGTRAP: ::c_int = 5; pub const GLOB_APPEND : ::c_int = 0x0001; @@ -864,13 +869,15 @@ pub const B57600: speed_t = 57600; pub const B76800: speed_t = 76800; pub const B115200: speed_t = 115200; pub const B230400: speed_t = 230400; -pub const B460800: speed_t = 460800; -pub const B921600: speed_t = 921600; pub const EXTA: speed_t = 19200; pub const EXTB: speed_t = 38400; pub const SEM_FAILED: *mut sem_t = 0 as *mut sem_t; +pub const CRTSCTS: ::tcflag_t = 0x00030000; + +pub const AT_FDCWD: ::c_int = -100; + f! { pub fn WIFCONTINUED(status: ::c_int) -> bool { status == 0x13 @@ -980,6 +987,8 @@ extern { base: ::locale_t) -> ::locale_t; pub fn uselocale(loc: ::locale_t) -> ::locale_t; pub fn querylocale(mask: ::c_int, loc: ::locale_t) -> *const ::c_char; + pub fn accept4(s: ::c_int, addr: *mut ::sockaddr, + addrlen: *mut ::socklen_t, flags: ::c_int) -> ::c_int; pub fn pthread_set_name_np(tid: ::pthread_t, name: *const ::c_char); pub fn pthread_attr_get_np(tid: ::pthread_t, attr: *mut ::pthread_attr_t) -> ::c_int; @@ -999,35 +1008,12 @@ extern { pub fn getpriority(which: ::c_int, who: ::c_int) -> ::c_int; pub fn setpriority(which: ::c_int, who: ::c_int, prio: ::c_int) -> ::c_int; - pub fn openat(dirfd: ::c_int, pathname: *const ::c_char, - flags: ::c_int, ...) -> ::c_int; - pub fn faccessat(dirfd: ::c_int, pathname: *const ::c_char, - mode: ::c_int, flags: ::c_int) -> ::c_int; - pub fn fchmodat(dirfd: ::c_int, pathname: *const ::c_char, - mode: ::mode_t, flags: ::c_int) -> ::c_int; - pub fn fchownat(dirfd: ::c_int, pathname: *const ::c_char, - owner: ::uid_t, group: ::gid_t, - flags: ::c_int) -> ::c_int; - pub fn fstatat(dirfd: ::c_int, pathname: *const ::c_char, - buf: *mut stat, flags: ::c_int) -> ::c_int; - pub fn linkat(olddirfd: ::c_int, oldpath: *const ::c_char, - newdirfd: ::c_int, newpath: *const ::c_char, - flags: ::c_int) -> ::c_int; - pub fn mkdirat(dirfd: ::c_int, pathname: *const ::c_char, - mode: ::mode_t) -> ::c_int; - pub fn mknodat(dirfd: ::c_int, pathname: *const ::c_char, - mode: ::mode_t, dev: dev_t) -> ::c_int; - pub fn readlinkat(dirfd: ::c_int, pathname: *const ::c_char, - buf: *mut ::c_char, bufsiz: ::size_t) -> ::ssize_t; - pub fn renameat(olddirfd: ::c_int, oldpath: *const ::c_char, - newdirfd: ::c_int, newpath: *const ::c_char) - -> ::c_int; - pub fn symlinkat(target: *const ::c_char, newdirfd: ::c_int, - linkpath: *const ::c_char) -> ::c_int; - pub fn unlinkat(dirfd: ::c_int, pathname: *const ::c_char, - flags: ::c_int) -> ::c_int; - pub fn mkfifoat(dirfd: ::c_int, pathname: *const ::c_char, - mode: ::mode_t) -> ::c_int; + pub fn fdopendir(fd: ::c_int) -> *mut ::DIR; + + pub fn mknodat(dirfd: ::c_int, pathname: *const ::c_char, + mode: ::mode_t, dev: dev_t) -> ::c_int; + pub fn mkfifoat(dirfd: ::c_int, pathname: *const ::c_char, + mode: ::mode_t) -> ::c_int; pub fn pthread_condattr_getclock(attr: *const pthread_condattr_t, clock_id: *mut clockid_t) -> ::c_int; pub fn pthread_condattr_setclock(attr: *mut pthread_condattr_t, -- cgit v1.2.1