Skip to content

Commit

Permalink
free already checks for null
Browse files Browse the repository at this point in the history
  • Loading branch information
Arlie Davis committed Jun 12, 2024
1 parent 25918dc commit cbeafc6
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions crates/libs/core/src/imp/heap.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,6 @@ pub unsafe fn heap_free(ptr: *mut c_void) {
fn free(ptr: *mut c_void);
}

if !ptr.is_null() {
free(ptr);
}
free(ptr);
}
}

0 comments on commit cbeafc6

Please sign in to comment.