From dfed7d19acb28512dd702b82a69055428fdf0867 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Tue, 4 Nov 2003 09:32:16 +0000 Subject: [PATCH] (store_char): Use x2nrealloc rather than xrealloc. --- src/pr.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/pr.c b/src/pr.c index f8184883b6..8ae0011af4 100644 --- a/src/pr.c +++ b/src/pr.c @@ -2013,8 +2013,7 @@ store_char (int c) if (buff_current >= buff_allocated) { /* May be too generous. */ - buff_allocated = 2 * buff_allocated; - buff = xrealloc (buff, buff_allocated * sizeof (char)); + buff = x2nrealloc (buff, &buff_allocated, sizeof *buff); } buff[buff_current++] = (char) c; } -- 2.47.2