Skip to content

Commit

Permalink
Fix clippy warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
philipc committed Oct 4, 2024
1 parent 930fe2a commit 7b34028
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions crates/rewrite/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -249,9 +249,9 @@ fn main() -> Result<()> {
let mut buf = io::BufReader::new(file);
let mut line = Vec::new();
while buf.read_until(b'\n', &mut line)? != 0 {
if line.ends_with(&[b'\n']) {
if line.ends_with(b"\n") {
line.pop();
if line.ends_with(&[b'\r']) {
if line.ends_with(b"\r") {
line.pop();
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/read/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1006,7 +1006,7 @@ impl<'data> CompressedData<'data> {
},
),
) => {
input = &input
input = input
.get(length as usize..)
.read_error("Invalid zstd compressed data")?;
continue;
Expand Down

0 comments on commit 7b34028

Please sign in to comment.