mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-02-16 17:24:23 +00:00
[MPS] Clear a new thread's pdl, avoiding crashes (bug#77024)
* src/thread.c (Fmake_thread): Use 'xzalloc', not 'xmalloc', to allocate new specpdl.
This commit is contained in:
parent
dfe1a69abd
commit
d488239a2e
1 changed files with 1 additions and 1 deletions
|
|
@ -904,7 +904,7 @@ If NAME is given, it must be a string; it names the new thread. */)
|
|||
new_thread->m_current_buffer = current_thread->m_current_buffer;
|
||||
|
||||
ptrdiff_t size = 50;
|
||||
union specbinding *pdlvec = xmalloc ((1 + size) * sizeof (union specbinding));
|
||||
union specbinding *pdlvec = xzalloc ((1 + size) * sizeof (union specbinding));
|
||||
new_thread->m_specpdl = pdlvec + 1; /* Skip the dummy entry. */
|
||||
new_thread->m_specpdl_end = new_thread->m_specpdl + size;
|
||||
new_thread->m_specpdl_ptr = new_thread->m_specpdl;
|
||||
|
|
|
|||
Loading…
Reference in a new issue