diff --git a/components/hashglobe/src/table.rs b/components/hashglobe/src/table.rs index 45dcb2673fa2..71212ccf6ab8 100644 --- a/components/hashglobe/src/table.rs +++ b/components/hashglobe/src/table.rs @@ -777,13 +777,16 @@ impl RawTable { // FORK NOTE: Uses alloc shim instead of Heap.alloc - let buffer = alloc(size, alignment); + let buffer: *mut u8 = alloc(size, alignment); if buffer.is_null() { return Err(FailedAllocationError { reason: "out of memory when allocating RawTable" }); } + // FORK NOTE: poison the entire buffer rather than leaving it uninitialized. + ptr::write_bytes(buffer, 0xe7, size); + let hashes = buffer.offset(hash_offset as isize) as *mut HashUint; Ok(RawTable {