File tree 2 files changed +3
-5
lines changed 2 files changed +3
-5
lines changed Original file line number Diff line number Diff line change 35
35
//! from [rust-spidev](https://github.com/posborne/rust-spidev).
36
36
//!
37
37
//! ```
38
- //! #[macro_use] extern crate nix;
39
- //!
40
38
//! #[allow(non_camel_case_types)]
41
39
//! pub struct spi_ioc_transfer {
42
40
//! pub tx_buf: u64,
Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ impl ForkResult {
59
59
/// println!("Continuing execution in parent process, new child has pid: {}", child);
60
60
/// }
61
61
/// Ok(ForkResult::Child) => println!("I'm a new child process"),
62
- /// Err(e ) => println!("Fork failed"),
62
+ /// Err(_ ) => println!("Fork failed"),
63
63
/// }
64
64
/// ```
65
65
///
@@ -272,7 +272,7 @@ pub fn fchdir(dirfd: RawFd) -> Result<()> {
272
272
/// - the path already exists
273
273
/// - the path name is too long (longer than `PATH_MAX`, usually 4096 on linux, 1024 on OS X)
274
274
///
275
- /// For a full list consult
275
+ /// For a full list consult
276
276
/// [man mkdir(2)](http://man7.org/linux/man-pages/man2/mkdir.2.html#ERRORS)
277
277
///
278
278
/// # Example
@@ -798,7 +798,7 @@ pub fn sleep(seconds: libc::c_uint) -> c_uint {
798
798
/// ```rust
799
799
/// use nix::unistd;
800
800
///
801
- /// let fd = match unistd::mkstemp("/tmp/tempfile_XXXXXX") {
801
+ /// let _ = match unistd::mkstemp("/tmp/tempfile_XXXXXX") {
802
802
/// Ok((fd, path)) => {
803
803
/// unistd::unlink(path.as_path()).unwrap(); // flag file to be deleted at app termination
804
804
/// fd
You can’t perform that action at this time.
0 commit comments