summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex AUVOLAT <alexis211@gmail.com>2012-05-27 18:41:06 +0200
committerAlex AUVOLAT <alexis211@gmail.com>2012-05-27 18:41:06 +0200
commit4d9459b1580cf1667a98dfd1273b926a5a9706c9 (patch)
treea11a3bad727449775d853504bceb6244e36844c8
parent2e28873f23d2cf073fdddfecdc278b0f44b2789b (diff)
downloadTCE-4d9459b1580cf1667a98dfd1273b926a5a9706c9.tar.gz
TCE-4d9459b1580cf1667a98dfd1273b926a5a9706c9.zip
Minor change, bump.
-rw-r--r--src/user/lib/libc/std/stdio.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/user/lib/libc/std/stdio.c b/src/user/lib/libc/std/stdio.c
index 196c554..12064be 100644
--- a/src/user/lib/libc/std/stdio.c
+++ b/src/user/lib/libc/std/stdio.c
@@ -31,8 +31,7 @@ void vfprintf(FILE f, const char *fmt, va_list ap) {
va_copy(ap2, ap);
int l = printf_str_len(fmt, ap2);
va_end(ap2);
- char* buf = (char*) malloc(l+1);
+ char buf[l+1];
l = vsprintf(buf, fmt, ap);
if (l > 0) write(f, 0, l, buf);
- free(buf);
}