From 907a9dd8c73d41cb570db8d7b1f3fc666f5e5f49 Mon Sep 17 00:00:00 2001 From: Junho Choi Date: Thu, 20 Jan 2022 17:30:27 -0800 Subject: [PATCH] Build with nix-rust master branch --- apps/Cargo.toml | 8 ++------ apps/src/bin/quiche-server.rs | 4 ++-- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/apps/Cargo.toml b/apps/Cargo.toml index d94ea905e0..c2cd20407a 100644 --- a/apps/Cargo.toml +++ b/apps/Cargo.toml @@ -26,12 +26,8 @@ log = "0.4" ring = "0.16" quiche = { path = "../quiche" } libc = "0.2" -# Needs update once merged to upstream -# https://github.com/nix-rust/nix/pull/1564 -nix = { git = "https://github.com/ghedo/nix.git", branch = "so_txtime" } - -[profile.release] -debug = true +# TODO: Update when there is a release tag +nix = { git = "https://github.com/nix-rust/nix.git", branch = "master" } [lib] crate-type = ["lib"] diff --git a/apps/src/bin/quiche-server.rs b/apps/src/bin/quiche-server.rs index 4617f5f26b..c675ed9f35 100644 --- a/apps/src/bin/quiche-server.rs +++ b/apps/src/bin/quiche-server.rs @@ -611,7 +611,7 @@ fn set_txtime_sockopt(sock: &net::UdpSocket) -> io::Result<()> { use nix::sys::socket::sockopt::TxTime; use std::os::unix::io::AsRawFd; - let config = libc::sock_txtime { + let config = nix::libc::sock_txtime { clockid: libc::CLOCK_MONOTONIC, flags: 0, }; @@ -637,7 +637,7 @@ fn set_txtime_sockopt(_: &net::UdpSocket) -> io::Result<()> { /// sendmsg syscall also includes the time the packet needs to be /// sent by the kernel in msghdr. /// -/// Note that sendmsg syscal is used only on linux platforms. +/// Note that sendmsg syscall is used only on linux platforms. #[cfg(target_os = "linux")] fn send_to( sock: &mio::net::UdpSocket, send_buf: &[u8], send_info: &quiche::SendInfo,