Skip to content

Commit

Permalink
Merge pull request #6292 from lcheylus/clippy-sort
Browse files Browse the repository at this point in the history
sort: disable clippy::suspicious_open_options on OpenBSD
  • Loading branch information
cakebaker authored Apr 30, 2024
2 parents 277c939 + ee4392e commit b8aa4e1
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/uu/sort/src/sort.rs
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,9 @@ impl Output {
let file = if let Some(name) = name {
// This is different from `File::create()` because we don't truncate the output yet.
// This allows using the output file as an input file.
#[allow(clippy::suspicious_open_options)]
// clippy::suspicious_open_options supported only for Rust >= 1.77.0
// Rust version = 1.76 on OpenBSD stable/7.5
#[cfg_attr(not(target_os = "openbsd"), allow(clippy::suspicious_open_options))]
let file = OpenOptions::new()
.write(true)
.create(true)
Expand Down

0 comments on commit b8aa4e1

Please sign in to comment.