Merge from vendor branch OPENSSH:
[dragonfly.git] / contrib / bc / lib / vfprintf.c
1 /* vfprintf.c -- this was provided for minix.  It may not
2    work on any other system. */
3
4 #include "config.h"
5 #ifndef HAVE_VPRINTF
6 #ifndef HAVE_DOPRINT
7  #error need vfprintf() or doprint()
8 #else
9
10 #ifdef HAVE_LIB_H
11 #include <lib.h>
12 #endif
13 #ifdef HAVE_STDARG_H
14 #include <stdarg.h>
15 #endif
16 #ifdef HAVE_STDIO_H
17 #include <stdio.h>
18 #endif
19
20 int vfprintf(file, format, argp)
21 FILE *file;
22 _CONST char *format;
23 va_list argp;
24 {
25   _doprintf(file, format, argp);
26   if (testflag(file, PERPRINTF)) fflush(file);
27   return 0;
28 }
29
30 #endif /* HAVE_DOPRINT */
31 #endif /* !HAVE_VFPRINTF */