Skip to content

Commit

Permalink
Correcting Len type for non-aarch64 Android targets.
Browse files Browse the repository at this point in the history
Signed-off-by: Nicholas Rishel <[email protected]>
  • Loading branch information
NickAtAccuPS committed May 4, 2018
1 parent e2ea728 commit 5146dc0
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@ pub use listener::UnixListener;
pub use datagram::UnixDatagram;

#[cfg(not(all(target_arch = "aarch64",target_os = "android")))]
type Len = u32;
type Len = libc::socklen_t;
// Match Android weirdness for aarch64 found in libc.
#[cfg(all(target_arch = "aarch64",target_os = "android"))]
type Len = i32;
type Len = libc::c_int;

fn cvt(i: libc::c_int) -> io::Result<libc::c_int> {
if i == -1 {
Expand Down

0 comments on commit 5146dc0

Please sign in to comment.