Skip to content

Commit

Permalink
fix(c_api): use correct cfg for pointer width
Browse files Browse the repository at this point in the history
  • Loading branch information
oyvindln committed Dec 16, 2024
1 parent b3b1604 commit f6c3b45
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -297,13 +297,13 @@ unmangle!(
}
);

#[cfg(target_bit_width = "64")]
#[cfg(target_pointer_width = "64")]
#[inline]
fn buffer_too_large(source_len: c_ulong, dest_len: c_ulong) -> bool {
(source_len | dest_len) > 0xFFFFFFFF
}

#[cfg(not(target_bit_width = "64"))]
#[cfg(not(target_pointer_width = "64"))]
#[inline]
fn buffer_too_large(_source_len: c_ulong, _dest_len: c_ulong) -> bool {
false
Expand Down

0 comments on commit f6c3b45

Please sign in to comment.