summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2003-11-04 09:27:54 +0000
committerJim Meyering <jim@meyering.net>2003-11-04 09:27:54 +0000
commite1c6989ecf7d49f524286f587b447b7b632de5c8 (patch)
tree931125eecec102f1535c3e47f34609341aca6139 /src
parenteab4bc527834d55459659f4438fdb34ddb2efd86 (diff)
downloadcoreutils-e1c6989ecf7d49f524286f587b447b7b632de5c8.tar.xz
(show_date): Use x2nrealloc rather than xrealloc.
Diffstat (limited to 'src')
-rw-r--r--src/date.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/date.c b/src/date.c
index 6d9333833..aa4b6a613 100644
--- a/src/date.c
+++ b/src/date.c
@@ -528,8 +528,7 @@ show_date (const char *format, struct timespec when)
while (1)
{
int done;
- out_length += 200;
- out = xrealloc (out, out_length);
+ out = x2nrealloc (out, &out_length, sizeof *out);
/* Mark the first byte of the buffer so we can detect the case
of nstrftime producing an empty string. Otherwise, this loop