Skip to content

Commit

Permalink
clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
rosaliedewinther committed Dec 8, 2024
1 parent 4050869 commit 299131c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/reader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -229,8 +229,8 @@ impl<R: Read + Seek> VdbReader<R> {
gd: &GridDescriptor,
count: usize,
) -> Result<Vec<T>, ParseError> {
if count <= 0 {
return Ok(vec![T::zeroed(); count as usize]);
if count == 0 {
return Ok(vec![T::zeroed(); count]);
}
Ok(if gd.compression.contains(Compression::BLOSC) {
let num_compressed_bytes = reader.read_i64::<LittleEndian>()?;
Expand Down

0 comments on commit 299131c

Please sign in to comment.