diff options
| author | Barton E. Schaefer <schaefer@zsh.org> | 2016-10-19 07:31:46 -0700 |
|---|---|---|
| committer | Barton E. Schaefer <schaefer@zsh.org> | 2016-10-19 07:31:46 -0700 |
| commit | b2d280038f97111144ce8aeb8ec293510b6b8e21 (patch) | |
| tree | 155351bdc4c5a151f487cc26511aba63c5371407 | |
| parent | 39678: metafication of printf %q argument and result (diff) | |
| download | zsh-b2d280038f97111144ce8aeb8ec293510b6b8e21.tar zsh-b2d280038f97111144ce8aeb8ec293510b6b8e21.tar.gz zsh-b2d280038f97111144ce8aeb8ec293510b6b8e21.tar.bz2 zsh-b2d280038f97111144ce8aeb8ec293510b6b8e21.tar.lz zsh-b2d280038f97111144ce8aeb8ec293510b6b8e21.tar.xz zsh-b2d280038f97111144ce8aeb8ec293510b6b8e21.tar.zst zsh-b2d280038f97111144ce8aeb8ec293510b6b8e21.zip | |
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.
| -rw-r--r-- | ChangeLog | 4 | ||||
| -rw-r--r-- | Src/mem.c | 3 |
2 files changed, 6 insertions, 1 deletions
@@ -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 @@ -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 |
