Skip to content

Commit

Permalink
use raw ptr for potentially racy load (#240)
Browse files Browse the repository at this point in the history
  • Loading branch information
RalfJung authored and carllerche committed Dec 21, 2018
1 parent 9504447 commit 42b6696
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/bytes.rs
Expand Up @@ -2467,7 +2467,7 @@ impl Inner {
// function.
let prev = unsafe {
let p: &AtomicPtr<Shared> = &self.arc;
let p: &usize = mem::transmute(p);
let p: *const usize = mem::transmute(p);
*p
};

Expand Down

0 comments on commit 42b6696

Please sign in to comment.