From 3d8df08329ead190fa72186255020bdcb54a177d Mon Sep 17 00:00:00 2001 From: Andrew Walbran Date: Mon, 4 Dec 2023 15:09:58 +0000 Subject: tokio: update nix dependency to 0.27.1 (#6190) This is a cherry-pick from upstream as it has not been released yet. Bug: 314091492 Test: m rust Change-Id: If7d3fe705c8d9d638bafc464a49daee6dea379ab --- Cargo.toml | 4 ++-- Cargo.toml.orig | 4 ++-- tests/io_async_fd.rs | 11 +++++++++-- 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 61e58ce..6728a90 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -205,10 +205,10 @@ version = "1.1.1" optional = true [target."cfg(unix)".dev-dependencies.libc] -version = "0.2.145" +version = "0.2.149" [target."cfg(unix)".dev-dependencies.nix] -version = "0.26" +version = "0.27.1" features = [ "fs", "socket", diff --git a/Cargo.toml.orig b/Cargo.toml.orig index 19384b7..069bb13 100644 --- a/Cargo.toml.orig +++ b/Cargo.toml.orig @@ -122,8 +122,8 @@ libc = { version = "0.2.145", optional = true } signal-hook-registry = { version = "1.1.1", optional = true } [target.'cfg(unix)'.dev-dependencies] -libc = { version = "0.2.145" } -nix = { version = "0.26", default-features = false, features = ["fs", "socket"] } +libc = { version = "0.2.149" } +nix = { version = "0.27.1", default-features = false, features = ["fs", "socket"] } [target.'cfg(windows)'.dependencies.windows-sys] version = "0.48" diff --git a/tests/io_async_fd.rs b/tests/io_async_fd.rs index 7abd592..49b5a68 100644 --- a/tests/io_async_fd.rs +++ b/tests/io_async_fd.rs @@ -1,7 +1,7 @@ #![warn(rust_2018_idioms)] #![cfg(all(unix, feature = "full"))] -use std::os::unix::io::{AsRawFd, RawFd}; +use std::os::unix::io::{AsRawFd, IntoRawFd, RawFd}; use std::sync::{ atomic::{AtomicBool, Ordering}, Arc, @@ -132,7 +132,14 @@ fn socketpair() -> (FileDescriptor, FileDescriptor) { SockFlag::empty(), ) .expect("socketpair"); - let fds = (FileDescriptor { fd: fd_a }, FileDescriptor { fd: fd_b }); + let fds = ( + FileDescriptor { + fd: fd_a.into_raw_fd(), + }, + FileDescriptor { + fd: fd_b.into_raw_fd(), + }, + ); set_nonblocking(fds.0.fd); set_nonblocking(fds.1.fd); -- cgit v1.2.3 From e05a4c03ef5f3606abe6ef3d58ad08f44a4dc5d2 Mon Sep 17 00:00:00 2001 From: Aditya Choudhary Date: Tue, 30 Jan 2024 13:42:03 +0000 Subject: [DON'T BLOCK] Test ownership migration rules This CL is created as a best effort to migrate test targets to the new android ownership model. If you find incorrect or unnecessary attribution in this CL, please create a separate CL to fix that. For more details please refer to the link below, Bug: 304529413 Test: N/A Change-Id: Ib1712b33f62adad50f624a5d919c72ee98606bde --- Android.bp | 1 + 1 file changed, 1 insertion(+) diff --git a/Android.bp b/Android.bp index 4cd7d24..07952cb 100644 --- a/Android.bp +++ b/Android.bp @@ -2,6 +2,7 @@ // Do not modify this file as changes will be overridden on upgrade. package { + default_team: "trendy_team_android_rust", default_applicable_licenses: ["external_rust_crates_tokio_license"], } -- cgit v1.2.3