2 Copyright © 1995-2012, The AROS Development Team. All rights reserved.
5 C99 function vfprintf()
7 /* Original source from libnix */
10 #include <proto/dos.h>
16 static int __putc(int c
, void *fh
);
18 /*****************************************************************************
31 Format a list of arguments and print them on the specified stream.
34 stream - A stream on which one can write
35 format - A printf() format string.
36 args - A list of arguments for the format string.
39 The number of characters written.
51 ******************************************************************************/
53 fdesc
*fdesc
= __getfdesc(stream
->fd
);
61 return __vcformat ((void *)BADDR(fdesc
->fcb
->handle
), __putc
, format
, args
);
65 static int __putc(int c
, void *fhp
)
67 BPTR fh
= MKBADDR(fhp
);
68 if (FPutC(fh
, c
) == EOF
)
70 errno
= __stdc_ioerr2errno(IoErr());