summaryrefslogtreecommitdiffstats
path: root/libc/stdio/vdprintf.c
diff options
context:
space:
mode:
Diffstat (limited to 'libc/stdio/vdprintf.c')
-rw-r--r--libc/stdio/vdprintf.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/libc/stdio/vdprintf.c b/libc/stdio/vdprintf.c
index 4e066f169..67adf47be 100644
--- a/libc/stdio/vdprintf.c
+++ b/libc/stdio/vdprintf.c
@@ -5,10 +5,17 @@
* Dedicated to Toni. See uClibc/DEDICATION.mjn3 for details.
*/
+#include <features.h>
+
+#ifdef __USE_GNU
#include "_stdio.h"
#include <stdarg.h>
-int attribute_hidden __vdprintf(int filedes, const char * __restrict format, va_list arg)
+libc_hidden_proto(vfprintf)
+libc_hidden_proto(fflush_unlocked)
+
+libc_hidden_proto(vdprintf)
+int vdprintf(int filedes, const char * __restrict format, va_list arg)
{
FILE f;
int rv;
@@ -51,11 +58,11 @@ int attribute_hidden __vdprintf(int filedes, const char * __restrict format, va_
#endif
f.__nextopen = NULL;
- rv = __vfprintf(&f, format, arg);
+ rv = vfprintf(&f, format, arg);
#ifdef __STDIO_BUFFERS
/* If not buffering, then fflush is unnecessary. */
- if ((rv > 0) && __fflush_unlocked(&f)) {
+ if ((rv > 0) && fflush_unlocked(&f)) {
rv = -1;
}
#endif
@@ -64,4 +71,5 @@ int attribute_hidden __vdprintf(int filedes, const char * __restrict format, va_
return rv;
}
-strong_alias(__vdprintf,vdprintf)
+libc_hidden_def(vdprintf)
+#endif