diff options
author | sateffen <sateffen@gmail.com> | 2016-07-11 08:36:52 +0000 |
---|---|---|
committer | sateffen <sateffen@gmail.com> | 2016-07-11 08:36:52 +0000 |
commit | 69e89a194ea0b9db6b6d54a70dae7d70ce4bc32d (patch) | |
tree | b54c10e5d69e8d65f810e69d7ee93e8aa03a5712 | |
parent | 14a4d154a38198e4765ed880f9a32e70a697b2cd (diff) | |
download | rust-libc-69e89a194ea0b9db6b6d54a70dae7d70ce4bc32d.tar.gz |
Refactored linger struct dry
-rw-r--r-- | src/unix/bsd/apple/mod.rs | 5 | ||||
-rw-r--r-- | src/unix/bsd/freebsdlike/mod.rs | 5 | ||||
-rw-r--r-- | src/unix/bsd/openbsdlike/mod.rs | 5 | ||||
-rw-r--r-- | src/unix/mod.rs | 5 | ||||
-rw-r--r-- | src/unix/notbsd/android/mod.rs | 5 | ||||
-rw-r--r-- | src/unix/notbsd/linux/mips.rs | 5 | ||||
-rw-r--r-- | src/unix/notbsd/linux/musl/b32/arm.rs | 5 | ||||
-rw-r--r-- | src/unix/notbsd/linux/musl/b32/asmjs.rs | 5 | ||||
-rw-r--r-- | src/unix/notbsd/linux/musl/b32/mips.rs | 5 | ||||
-rw-r--r-- | src/unix/notbsd/linux/musl/b32/x86.rs | 5 | ||||
-rw-r--r-- | src/unix/notbsd/linux/musl/b64/mod.rs | 5 | ||||
-rw-r--r-- | src/unix/notbsd/linux/other/mod.rs | 5 | ||||
-rw-r--r-- | src/unix/solaris/mod.rs | 5 |
13 files changed, 5 insertions, 60 deletions
diff --git a/src/unix/bsd/apple/mod.rs b/src/unix/bsd/apple/mod.rs index 7851ad1969..f4235fdcc0 100644 --- a/src/unix/bsd/apple/mod.rs +++ b/src/unix/bsd/apple/mod.rs @@ -287,11 +287,6 @@ s! { pub int_p_sign_posn: ::c_char, pub int_n_sign_posn: ::c_char, } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const LC_COLLATE_MASK: ::c_int = (1 << 0); diff --git a/src/unix/bsd/freebsdlike/mod.rs b/src/unix/bsd/freebsdlike/mod.rs index ef860d8465..e7e04a78a2 100644 --- a/src/unix/bsd/freebsdlike/mod.rs +++ b/src/unix/bsd/freebsdlike/mod.rs @@ -155,11 +155,6 @@ s! { pub struct _sem { data: [u32; 4], } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const LC_COLLATE_MASK: ::c_int = (1 << 0); diff --git a/src/unix/bsd/openbsdlike/mod.rs b/src/unix/bsd/openbsdlike/mod.rs index c2f8d85f5e..53e7c3c2d1 100644 --- a/src/unix/bsd/openbsdlike/mod.rs +++ b/src/unix/bsd/openbsdlike/mod.rs @@ -54,11 +54,6 @@ s! { pub l_type: ::c_short, pub l_whence: ::c_short, } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const D_T_FMT: ::nl_item = 0; diff --git a/src/unix/mod.rs b/src/unix/mod.rs index d799ec13f3..214f2cc043 100644 --- a/src/unix/mod.rs +++ b/src/unix/mod.rs @@ -109,6 +109,11 @@ s! { pub ws_xpixel: ::c_ushort, pub ws_ypixel: ::c_ushort, } + + pub struct linger { + pub l_onoff: ::c_int, + pub l_linger: ::c_int, + } } pub const SIG_DFL: sighandler_t = 0 as sighandler_t; diff --git a/src/unix/notbsd/android/mod.rs b/src/unix/notbsd/android/mod.rs index a96d278969..6ddcfafc5d 100644 --- a/src/unix/notbsd/android/mod.rs +++ b/src/unix/notbsd/android/mod.rs @@ -99,11 +99,6 @@ s! { pub struct sem_t { count: ::c_uint, } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const BUFSIZ: ::c_uint = 1024; diff --git a/src/unix/notbsd/linux/mips.rs b/src/unix/notbsd/linux/mips.rs index a9611b2b11..fa5a2a3669 100644 --- a/src/unix/notbsd/linux/mips.rs +++ b/src/unix/notbsd/linux/mips.rs @@ -198,11 +198,6 @@ s! { __size: [::c_char; 32], __align: [::c_long; 0], } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const BUFSIZ: ::c_uint = 8192; diff --git a/src/unix/notbsd/linux/musl/b32/arm.rs b/src/unix/notbsd/linux/musl/b32/arm.rs index a9dfe12d8b..5d648618e3 100644 --- a/src/unix/notbsd/linux/musl/b32/arm.rs +++ b/src/unix/notbsd/linux/musl/b32/arm.rs @@ -82,11 +82,6 @@ s! { pub f_flags: ::c_ulong, pub f_spare: [::c_ulong; 4], } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const O_DIRECT: ::c_int = 0x4000; diff --git a/src/unix/notbsd/linux/musl/b32/asmjs.rs b/src/unix/notbsd/linux/musl/b32/asmjs.rs index f813150e3b..93e4ab6b6d 100644 --- a/src/unix/notbsd/linux/musl/b32/asmjs.rs +++ b/src/unix/notbsd/linux/musl/b32/asmjs.rs @@ -82,11 +82,6 @@ s! { pub f_flags: ::c_ulong, pub f_spare: [::c_ulong; 4], } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const O_DIRECT: ::c_int = 0x4000; diff --git a/src/unix/notbsd/linux/musl/b32/mips.rs b/src/unix/notbsd/linux/musl/b32/mips.rs index f59458eaa7..f52d195322 100644 --- a/src/unix/notbsd/linux/musl/b32/mips.rs +++ b/src/unix/notbsd/linux/musl/b32/mips.rs @@ -81,11 +81,6 @@ s! { pub f_flags: ::c_ulong, pub f_spare: [::c_ulong; 5], } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const O_DIRECT: ::c_int = 0o100000; diff --git a/src/unix/notbsd/linux/musl/b32/x86.rs b/src/unix/notbsd/linux/musl/b32/x86.rs index e849efee44..9d057de7b9 100644 --- a/src/unix/notbsd/linux/musl/b32/x86.rs +++ b/src/unix/notbsd/linux/musl/b32/x86.rs @@ -95,11 +95,6 @@ s! { pub uc_sigmask: ::sigset_t, __private: [u8; 112], } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const O_DIRECT: ::c_int = 0x4000; diff --git a/src/unix/notbsd/linux/musl/b64/mod.rs b/src/unix/notbsd/linux/musl/b64/mod.rs index 8f48e0f4f7..0501c553c3 100644 --- a/src/unix/notbsd/linux/musl/b64/mod.rs +++ b/src/unix/notbsd/linux/musl/b64/mod.rs @@ -104,11 +104,6 @@ s! { pub struct sem_t { __val: [::c_int; 8], } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const __SIZEOF_PTHREAD_RWLOCK_T: usize = 56; diff --git a/src/unix/notbsd/linux/other/mod.rs b/src/unix/notbsd/linux/other/mod.rs index deda1a489d..2998fbc21e 100644 --- a/src/unix/notbsd/linux/other/mod.rs +++ b/src/unix/notbsd/linux/other/mod.rs @@ -130,11 +130,6 @@ s! { __size: [::c_char; 32], __align: [::c_long; 0], } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const RLIMIT_RSS: ::c_int = 5; diff --git a/src/unix/solaris/mod.rs b/src/unix/solaris/mod.rs index 0ef2e81d3d..56cb76ea94 100644 --- a/src/unix/solaris/mod.rs +++ b/src/unix/solaris/mod.rs @@ -318,11 +318,6 @@ s! { pub l_pid: ::pid_t, pub l_pad: [::c_long; 4] } - - pub struct linger { - pub l_onoff: ::c_int, - pub l_linger: ::c_int, - } } pub const LC_CTYPE: ::c_int = 0; |