diff options
author | bors[bot] <bors[bot]@users.noreply.github.com> | 2018-09-02 15:15:30 +0000 |
---|---|---|
committer | bors[bot] <bors[bot]@users.noreply.github.com> | 2018-09-02 15:15:30 +0000 |
commit | 82b51a2b5dd9b5567d4cf15f4bf931d9e39528d1 (patch) | |
tree | 9c3f8eefb8f022159d27cc2a8ffffbd0ff9d22a0 /src | |
parent | 70cce1a384ec21c6ba0ef38d64d2f67333e4b7d7 (diff) | |
parent | ecad72a18e798870ae3591c6ea49a2dd544ba5f3 (diff) | |
download | nix-82b51a2b5dd9b5567d4cf15f4bf931d9e39528d1.zip |
Merge #900
900: deps: update tempfile to 3 r=Susurrus a=ignatenkobrain
Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
Co-authored-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/sys/socket/mod.rs | 2 | ||||
-rw-r--r-- | src/unistd.rs | 12 |
2 files changed, 7 insertions, 7 deletions
diff --git a/src/sys/socket/mod.rs b/src/sys/socket/mod.rs index e9537c4b..4ee1acee 100644 --- a/src/sys/socket/mod.rs +++ b/src/sys/socket/mod.rs @@ -678,7 +678,7 @@ pub fn sendmsg<'a>(fd: RawFd, iov: &[IoVec<&'a [u8]>], cmsgs: &[ControlMessage<' { let mut ofs = 0; for cmsg in cmsgs { - let mut ptr = &mut cmsg_buffer[ofs..]; + let ptr = &mut cmsg_buffer[ofs..]; unsafe { cmsg.encode_into(ptr); } diff --git a/src/unistd.rs b/src/unistd.rs index 32d0405e..1f357c41 100644 --- a/src/unistd.rs +++ b/src/unistd.rs @@ -436,15 +436,15 @@ pub fn fchdir(dirfd: RawFd) -> Result<()> { /// # Example /// /// ```rust -/// extern crate tempdir; +/// extern crate tempfile; /// extern crate nix; /// /// use nix::unistd; /// use nix::sys::stat; -/// use tempdir::TempDir; +/// use tempfile::tempdir; /// /// fn main() { -/// let tmp_dir1 = TempDir::new("test_mkdir").unwrap(); +/// let tmp_dir1 = tempdir().unwrap(); /// let tmp_dir2 = tmp_dir1.path().join("new_dir"); /// /// // create new directory and give read, write and execute rights to the owner @@ -479,15 +479,15 @@ pub fn mkdir<P: ?Sized + NixPath>(path: &P, mode: Mode) -> Result<()> { /// # Example /// /// ```rust -/// extern crate tempdir; +/// extern crate tempfile; /// extern crate nix; /// /// use nix::unistd; /// use nix::sys::stat; -/// use tempdir::TempDir; +/// use tempfile::tempdir; /// /// fn main() { -/// let tmp_dir = TempDir::new("test_fifo").unwrap(); +/// let tmp_dir = tempdir().unwrap(); /// let fifo_path = tmp_dir.path().join("foo.pipe"); /// /// // create new fifo and give read, write and execute rights to the owner |