1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-09-04 10:41:11 +02:00

39680: correctly handle case of popping last arena

This mattered only when compiling with --enable-stack-allocation because
otherwise the heap was never completely empty.
This commit is contained in:
Barton E. Schaefer 2016-10-19 07:31:46 -07:00
parent 7e7e2d7e63
commit b2d280038f
2 changed files with 6 additions and 1 deletions

View file

@ -1,3 +1,7 @@
2016-10-19 Barton E. Schaefer <schaefer@zsh.org>
* 39680: Src/mem.c: correctly handle case of popping last arena
2016-10-19 Peter Stephenson <p.stephenson@samsung.com>
* 39678: Src/builtin.c, Test/D07multibyte.ztst: printf %q

View file

@ -497,7 +497,8 @@ popheap(void)
continue;
}
h->next = NULL;
}
} else if (hl == h) /* This is the last arena of all */
hl = NULL;
#ifdef USE_MMAP
munmap((void *) h, h->size);
#else