-
Notifications
You must be signed in to change notification settings - Fork 376
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add unsound advisory for
mimalloc
(#2098)
- Loading branch information
1 parent
6dbff23
commit e3df454
Showing
1 changed file
with
17 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
```toml | ||
[advisory] | ||
id = "RUSTSEC-0000-0000" | ||
package = "mimalloc" | ||
date = "2022-11-23" | ||
url = "https://github.com/purpleprotocol/mimalloc_rust/issues/87" | ||
informational = "unsound" | ||
|
||
[versions] | ||
patched = [">= 0.1.39"] | ||
``` | ||
|
||
# Mimalloc Can Allocate Memory with Bad Alignment | ||
This crate depended on a promise regarding alignments made by the author of the mimalloc allocator to avoid using aligned allocation functions where possible for performance reasons. | ||
Since then, the mimalloc allocator's logic changed, making it break this promise. | ||
This caused this crate to return memory with an incorrect alignment for some allocations, particularly those with large alignments. | ||
The flaw was fixed by always using the aligned allocation functions. |