Skip to content

Commit

Permalink
Bugfix: keep TLS data in sync
Browse files Browse the repository at this point in the history
  • Loading branch information
raoulstrackx committed Oct 14, 2022
1 parent 4891d57 commit c46185b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions library/std/src/sys/sgx/abi/tls/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ impl Tls {
rtabort!("TLS limit exceeded")
};
TLS_DESTRUCTOR[index].store(dtor.map_or(0, |f| f as usize), Ordering::Relaxed);
unsafe { Self::current() }.data[index].set(ptr::null_mut());
Key::from_index(index)
}

Expand Down

0 comments on commit c46185b

Please sign in to comment.