Browse Source

Fix compilation on Redox

Jeremy Soller 6 years ago
parent
commit
b2cc8f6d26
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/ld_so/linker.rs

+ 1 - 1
src/ld_so/linker.rs

@@ -53,7 +53,7 @@ unsafe fn allocate_tls(size: usize) -> Result<&'static mut [u8]> {
 // On Redox, reuse the current TCB
 // TODO: Consider adopting Linux behavior
 #[cfg(target_os = "redox")]
-unsafe fn allocate_tls(size: usize) -> Result<&'static [u8]> {
+unsafe fn allocate_tls(size: usize) -> Result<&'static mut [u8]> {
     let ptr = sys_mman::mmap(
         ptr::null_mut(),
         size,