1 #include <newlib.h>
2 
3 #ifdef _FVWRITE_IN_STREAMIO
4 
5 #include <stdio.h>
6 #include "fvwrite.h"
7 
8 /*
9  * Flush out all the vectors defined by the given uio,
10  * then reset it so that it can be reused.
11  */
12 int
__sprint(FILE * fp,register struct __suio * uio)13 __sprint (
14        FILE *fp,
15        register struct __suio *uio)
16 {
17 	register int err = 0;
18 
19 	if (uio->uio_resid == 0) {
20 		uio->uio_iovcnt = 0;
21 		return (0);
22 	}
23 	err = _sfvwrite(fp, uio);
24 	uio->uio_resid = 0;
25 	uio->uio_iovcnt = 0;
26 	return (err);
27 }
28 
29 #endif
30