vx32

Local 9vx git repository for patches.
git clone git://r-36.net/vx32
Log | Files | Refs

vsscanf.c (304B)


      1 #include <stdio.h>
      2 #include <stdarg.h>
      3 #include <string.h>
      4 
      5 int vsscanf(const char *s, const char *fmt, va_list arg)
      6 {
      7 	FILE f;
      8 	
      9 	memset(&f, 0, sizeof f);
     10 	f.fd = -1;
     11 	f.isstring = 1;
     12 	f.ibuf = (unsigned char*)s;
     13 	f.ipos = 0;
     14 	f.ilim = strlen(s);
     15 	f.imax = strlen(s);
     16 	
     17 	return vfscanf(&f, fmt, arg);
     18 }