In the situation with limited address space, together with fragmentation, it is possible for mmap() request in morecore() to fail when asking for required size + NPOOLPAGES, but succeed without the addend. Retry allocation there. PR: 259076 Reported by: Denis Koreshkov <dynamic-wind@mail.ru>
Also
crt_malloc: use uintptr_t instead of long for arithmetic on addresses