Commit 04dae60b authored by Gerd Moellmann's avatar Gerd Moellmann

(enter_namespace): Fix reallocation of

namespace_stack.
parent 67f2e119
......@@ -1156,8 +1156,9 @@ enter_namespace (name)
if (namespace_sp == namespace_stack_size)
{
int size = max (10, 2 * namespace_stack_size);
namespace_stack = (struct sym **) xrealloc ((void *)namespace_stack,
size);
namespace_stack
= (struct sym **) xrealloc ((void *)namespace_stack,
size * sizeof *namespace_stack);
namespace_stack_size = size;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment