aboutsummaryrefslogtreecommitdiff
path: root/ctru-sys/src/sys/socket.rs
diff options
context:
space:
mode:
authorFenrir <[email protected]>2017-06-06 15:05:51 -0600
committerFenrir <[email protected]>2017-07-10 11:30:57 -0600
commitcf1f07558a28aa00bc67b515863807a7639bc5b0 (patch)
treeb12018e5ec772499911b965af5ff191dee71c2a2 /ctru-sys/src/sys/socket.rs
parentMerge pull request #32 from FenrirWolf/libc-update (diff)
downloadarchived-ctru-rs-cf1f07558a28aa00bc67b515863807a7639bc5b0.tar.xz
archived-ctru-rs-cf1f07558a28aa00bc67b515863807a7639bc5b0.zip
Use bindgen for ctru_sys bindings
Diffstat (limited to 'ctru-sys/src/sys/socket.rs')
-rw-r--r--ctru-sys/src/sys/socket.rs75
1 files changed, 0 insertions, 75 deletions
diff --git a/ctru-sys/src/sys/socket.rs b/ctru-sys/src/sys/socket.rs
deleted file mode 100644
index 19d1cb1..0000000
--- a/ctru-sys/src/sys/socket.rs
+++ /dev/null
@@ -1,75 +0,0 @@
-/* automatically generated by rust-bindgen */
-
-#![allow(dead_code,
- non_camel_case_types,
- non_upper_case_globals,
- non_snake_case)]
-pub type socklen_t = ::libc::uint32_t;
-pub type sa_family_t = ::libc::uint16_t;
-#[repr(C)]
-#[derive(Copy, Clone)]
-#[derive(Debug)]
-pub struct sockaddr {
- pub sa_family: sa_family_t,
- pub sa_data: [::libc::c_char; 0usize],
-}
-impl ::core::default::Default for sockaddr {
- fn default() -> Self { unsafe { ::core::mem::zeroed() } }
-}
-#[repr(C)]
-#[derive(Copy, Clone)]
-#[derive(Debug)]
-pub struct sockaddr_storage {
- pub ss_family: sa_family_t,
- pub __ss_padding: [::libc::c_char; 26usize],
-}
-impl ::core::default::Default for sockaddr_storage {
- fn default() -> Self { unsafe { ::core::mem::zeroed() } }
-}
-#[repr(C)]
-#[derive(Copy, Clone)]
-#[derive(Debug)]
-pub struct linger {
- pub l_onoff: ::libc::c_int,
- pub l_linger: ::libc::c_int,
-}
-impl ::core::default::Default for linger {
- fn default() -> Self { unsafe { ::core::mem::zeroed() } }
-}
-extern "C" {
- pub fn accept(sockfd: ::libc::c_int, addr: *mut sockaddr,
- addrlen: *mut socklen_t) -> ::libc::c_int;
- pub fn bind(sockfd: ::libc::c_int, addr: *const sockaddr,
- addrlen: socklen_t) -> ::libc::c_int;
- pub fn closesocket(sockfd: ::libc::c_int) -> ::libc::c_int;
- pub fn connect(sockfd: ::libc::c_int, addr: *const sockaddr,
- addrlen: socklen_t) -> ::libc::c_int;
- pub fn getpeername(sockfd: ::libc::c_int, addr: *mut sockaddr,
- addrlen: *mut socklen_t) -> ::libc::c_int;
- pub fn getsockname(sockfd: ::libc::c_int, addr: *mut sockaddr,
- addrlen: *mut socklen_t) -> ::libc::c_int;
- pub fn getsockopt(sockfd: ::libc::c_int, level: ::libc::c_int,
- optname: ::libc::c_int, optval: *mut ::libc::c_void,
- optlen: *mut socklen_t) -> ::libc::c_int;
- pub fn listen(sockfd: ::libc::c_int, backlog: ::libc::c_int)
- -> ::libc::c_int;
- pub fn recv(sockfd: ::libc::c_int, buf: *mut ::libc::c_void, len: ::libc::size_t,
- flags: ::libc::c_int) -> ::libc::ssize_t;
- pub fn recvfrom(sockfd: ::libc::c_int, buf: *mut ::libc::c_void,
- len: ::libc::size_t, flags: ::libc::c_int,
- src_addr: *mut sockaddr, addrlen: *mut socklen_t)
- -> ::libc::ssize_t;
- pub fn send(sockfd: ::libc::c_int, buf: *const ::libc::c_void,
- len: ::libc::size_t, flags: ::libc::c_int) -> ::libc::ssize_t;
- pub fn sendto(sockfd: ::libc::c_int, buf: *const ::libc::c_void,
- len: ::libc::size_t, flags: ::libc::c_int,
- dest_addr: *const sockaddr, addrlen: socklen_t) -> ::libc::ssize_t;
- pub fn setsockopt(sockfd: ::libc::c_int, level: ::libc::c_int,
- optname: ::libc::c_int, optval: *const ::libc::c_void,
- optlen: socklen_t) -> ::libc::c_int;
- pub fn shutdown(sockfd: ::libc::c_int, how: ::libc::c_int)
- -> ::libc::c_int;
- pub fn socket(domain: ::libc::c_int, type_: ::libc::c_int,
- protocol: ::libc::c_int) -> ::libc::c_int;
- pub fn sockatmark(sockfd: ::libc::c_int) -> ::libc::c_int;
-}