summaryrefslogtreecommitdiff
path: root/lib/libc/stdio/vasprintf.c
diff options
context:
space:
mode:
authorchristos <christos@NetBSD.org>2009-10-25 20:44:13 +0000
committerchristos <christos@NetBSD.org>2009-10-25 20:44:13 +0000
commitcfbb35ed03a728123e8b9a6fc3e6f688657b2daa (patch)
tree0f40e7597aefe9c2df7b0b9131814df2b45f3869 /lib/libc/stdio/vasprintf.c
parent4cdf2079e4af97a8307d4da723b035c6cc63f3a0 (diff)
revert some of dsl's changes to make things build on i386; he can undo what
he wants when he comes back.
Diffstat (limited to 'lib/libc/stdio/vasprintf.c')
-rw-r--r--lib/libc/stdio/vasprintf.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libc/stdio/vasprintf.c b/lib/libc/stdio/vasprintf.c
index d5518c3b81b..3664d7ba120 100644
--- a/lib/libc/stdio/vasprintf.c
+++ b/lib/libc/stdio/vasprintf.c
@@ -1,4 +1,4 @@
-/* $NetBSD: vasprintf.c,v 1.11 2009/10/24 15:20:15 dsl Exp $ */
+/* $NetBSD: vasprintf.c,v 1.12 2009/10/25 20:44:13 christos Exp $ */
/*
* Copyright (c) 1997 Todd C. Miller <Todd.Miller@courtesan.com>
@@ -29,7 +29,7 @@
#include <sys/cdefs.h>
#if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: vasprintf.c,v 1.11 2009/10/24 15:20:15 dsl Exp $");
+__RCSID("$NetBSD: vasprintf.c,v 1.12 2009/10/25 20:44:13 christos Exp $");
#endif /* LIBC_SCCS and not lint */
#include <assert.h>
@@ -64,7 +64,7 @@ vasprintf(str, fmt, ap)
if (ret == -1)
goto err;
*f._p = '\0';
- _base = realloc(f._bf._base, ret + 1);
+ _base = realloc(f._bf._base, (size_t)(ret + 1));
if (_base == NULL)
goto err;
*str = (char *)_base;