|
|
1.1 ! root 1: /* @(#)vsprintf.c 1.1 */ ! 2: /*LINTLIBRARY*/ ! 3: #include <stdio.h> ! 4: #include <varargs.h> ! 5: ! 6: extern int _doprnt(); ! 7: ! 8: /*VARARGS2*/ ! 9: int ! 10: vsprintf(string, format, ap) ! 11: char *string, *format; ! 12: va_list ap; ! 13: { ! 14: register int count; ! 15: FILE siop; ! 16: ! 17: siop._cnt = 32767; ! 18: siop._base = siop._ptr = (unsigned char *)string; ! 19: siop._flag = _IOWRT; ! 20: siop._file = _NFILE; ! 21: count = _doprnt(format, ap, &siop); ! 22: *siop._ptr = '\0'; /* plant terminating null character */ ! 23: return(count); ! 24: } ! 25:
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.