Skip to content

Commit

Permalink
shred: make dependency on libc explicit
Browse files Browse the repository at this point in the history
  • Loading branch information
tertsdiepraam committed Mar 13, 2023
1 parent 039f9db commit bd0037b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions src/uu/shred/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ path = "src/shred.rs"
clap = { workspace=true }
rand = { workspace=true }
uucore = { workspace=true }
libc = { workspace=true }

[[bin]]
name = "shred"
Expand Down
4 changes: 3 additions & 1 deletion src/uu/shred/src/shred.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,16 @@
// spell-checker:ignore (words) wipesync prefill

use clap::{crate_version, Arg, ArgAction, Command};
#[cfg(unix)]
use libc::S_IWUSR;
use rand::{rngs::StdRng, seq::SliceRandom, Rng, SeedableRng};
use std::fs::{self, File, OpenOptions};
use std::io::{self, Seek, Write};
#[cfg(unix)]
use std::os::unix::prelude::PermissionsExt;
use std::path::{Path, PathBuf};
use uucore::display::Quotable;
use uucore::error::{FromIo, UResult, USimpleError, UUsageError};
use uucore::libc::S_IWUSR;
use uucore::{format_usage, help_about, help_section, help_usage, show, show_error, show_if_err};

const ABOUT: &str = help_about!("shred.md");
Expand Down

0 comments on commit bd0037b

Please sign in to comment.