From 5ece1728e2a47c56a22475affab317bdc4dccee6 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 6 May 1994 06:45:18 +0000 Subject: [PATCH] (error): Fix logic in call to xmalloc/xrealloc. --- src/eval.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/eval.c b/src/eval.c index 0643655f0f3..8aadc0b0a9a 100644 --- a/src/eval.c +++ b/src/eval.c @@ -1331,7 +1331,11 @@ error (m, a1, a2, a3) size *= 2; if (allocated) buffer = (char *) xrealloc (buffer, size); - buffer = (char *) xmalloc (size); + else + { + buffer = (char *) xmalloc (size); + allocated = 1; + } } string = build_string (buf); -- 2.39.5