mirror of git://git.musl-libc.org/musl
remove redundant check in memalign
the case where mem was already aligned is handled earlier in the function now.
This commit is contained in:
parent
70a92bc968
commit
4a30ba5ca4
|
@ -50,7 +50,7 @@ void *__memalign(size_t align, size_t len)
|
|||
((size_t *)new)[-1] = header&7 | end-new;
|
||||
((size_t *)end)[-2] = footer&7 | end-new;
|
||||
|
||||
if (new != mem) free(mem);
|
||||
free(mem);
|
||||
return new;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue