diff options
author | Denis Vlasenko <vda.linux@googlemail.com> | 2008-04-09 19:51:18 +0000 |
---|---|---|
committer | Denis Vlasenko <vda.linux@googlemail.com> | 2008-04-09 19:51:18 +0000 |
commit | 36ac7bee0f6b0be35eafd74e0fc865edd2352197 (patch) | |
tree | b557dfbf03da9612bc09906fa3fb7559f556fed8 /libc/stdio/vdprintf.c | |
parent | f1459b13206cee20f322a53bb659a8735e2c8de0 (diff) |
Factor out the core of vprintf() into separate function
vprintf_internal, so that:
* vprintf() does locking and __STDIO_STREAM_TRANS_TO_WRITE thing,
then calls vprintf_internal
* vsnprintf, vdprintf.c, vasprintf.c use
vprintf_internal directly
This makes sprintf faster (since it doesn't do any locking)
and stops it from pulling in fseek in static compile.
Diffstat (limited to 'libc/stdio/vdprintf.c')
-rw-r--r-- | libc/stdio/vdprintf.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/libc/stdio/vdprintf.c b/libc/stdio/vdprintf.c index 0c29eb109..9e1b22eaf 100644 --- a/libc/stdio/vdprintf.c +++ b/libc/stdio/vdprintf.c @@ -11,7 +11,6 @@ #include "_stdio.h" #include <stdarg.h> -libc_hidden_proto(vfprintf) libc_hidden_proto(fflush_unlocked) libc_hidden_proto(vdprintf) @@ -54,7 +53,7 @@ int vdprintf(int filedes, const char * __restrict format, va_list arg) #endif f.__nextopen = NULL; - rv = vfprintf(&f, format, arg); + rv = _vfprintf_internal(&f, format, arg); #ifdef __STDIO_BUFFERS /* If not buffering, then fflush is unnecessary. */ @@ -67,5 +66,4 @@ int vdprintf(int filedes, const char * __restrict format, va_list arg) return rv; } -libc_hidden_def(vdprintf) #endif |