Scans input from a stream under format control, using a variable argument list.
#include <stdio.h> int vfscanf ( FILE *fp, const char *format, va_list arg);
(IN) Points to the file.
(IN) Points to the format control string. See Scan Format Control Strings.
(OUT) Specifies a variable argument list where the scanned string is to be stored. The number of arguments in the list is determined by the format string.
If successful, returns the number of input items for which values were successfully scanned and stored. Otherwise, returns EOF when any of the following occur:
The scanning is terminated by reaching the end of the input stream
A matching failure is encountered
A read error occurs
If a read error occurs, vfscanf also sets the error indicator for the stream and sets errno to one of the following:
The vfscanf function scans input from the file designated by fp under control of the format parameter and stores it in the arg parameter.
The vfscanf function is equivalent to the fscanf function, with the variable arguments replaced with arg, which has been initialized using the va_start macro.