diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2009-11-17 05:33:47 +0100 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2009-11-17 05:33:47 +0100 |
commit | 995f15452a265190c222442758a21fed2233ba14 (patch) | |
tree | c2d02a2e095c092d45a0bc3560e777bc5cce9f7d | |
parent | f3e2818895a6f570a365001f625946a1b75c085a (diff) | |
download | busybox-w32-995f15452a265190c222442758a21fed2233ba14.tar.gz busybox-w32-995f15452a265190c222442758a21fed2233ba14.tar.bz2 busybox-w32-995f15452a265190c222442758a21fed2233ba14.zip |
libbb: fix vasprintf implementation
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r-- | libbb/platform.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libbb/platform.c b/libbb/platform.c index fdd388259..17ad3f75a 100644 --- a/libbb/platform.c +++ b/libbb/platform.c | |||
@@ -30,7 +30,8 @@ int FAST_FUNC vasprintf(char **string_ptr, const char *format, va_list p) | |||
30 | 30 | ||
31 | if (r < 128) { | 31 | if (r < 128) { |
32 | va_end(p2); | 32 | va_end(p2); |
33 | return xstrdup(buf); | 33 | *string_ptr = xstrdup(buf); |
34 | return r; | ||
34 | } | 35 | } |
35 | 36 | ||
36 | *string_ptr = xmalloc(r+1); | 37 | *string_ptr = xmalloc(r+1); |