mirror of
https://github.com/jemalloc/jemalloc.git
synced 2026-04-14 14:41:42 +03:00
Allow zero sized memalign to pass.
Instead of failing on assertions. Previously the same change was made for posix_memalign and aligned_alloc (#1554). Make memalign behave the same way even though it's obsolete.
This commit is contained in:
parent
6d181bc1b7
commit
1aba4f41a3
1 changed files with 1 additions and 0 deletions
|
|
@ -3052,6 +3052,7 @@ je_memalign(size_t alignment, size_t size) {
|
|||
static_opts_init(&sopts);
|
||||
dynamic_opts_init(&dopts);
|
||||
|
||||
sopts.bump_empty_aligned_alloc = true;
|
||||
sopts.min_alignment = 1;
|
||||
sopts.oom_string =
|
||||
"<jemalloc>: Error allocating aligned memory: out of memory\n";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue