Skip to content

Commit

Permalink
Clippy lint
Browse files Browse the repository at this point in the history
  • Loading branch information
magnusuMET committed Aug 9, 2024
1 parent 3f944c1 commit 8f9c9e8
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions netcdf/src/attribute.rs
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,6 @@ impl<'a> Attribute<'a> {
}
NC_STRING => {
let mut buf: Vec<*mut c_char> = vec![std::ptr::null_mut(); attlen];
let result;
checked_with_lock(|| unsafe {
nc_get_att_string(
self.ncid,
Expand All @@ -372,7 +371,7 @@ impl<'a> Attribute<'a> {
buf.as_mut_ptr().cast(),
)
})?;
result = buf
let result = buf
.iter()
.map(|cstr_pointer| unsafe {
if cstr_pointer.is_null() {
Expand Down

0 comments on commit 8f9c9e8

Please sign in to comment.