FreeBSD kernel kern code
|
#include <sys/cdefs.h>
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/ctype.h>
#include <sys/limits.h>
#include <sys/stddef.h>
#include <machine/stdarg.h>
Go to the source code of this file.
Macros | |
#define | BUF 32 /* Maximum length of numeric string. */ |
#define | LONG 0x01 /* l: long or double */ |
#define | SHORT 0x04 /* h: short */ |
#define | SUPPRESS 0x08 /* suppress assignment */ |
#define | POINTER 0x10 /* weird %p pointer (`fake hex') */ |
#define | NOSKIP 0x20 /* do not skip blanks */ |
#define | QUAD 0x400 |
#define | INTMAXT 0x800 /* j: intmax_t */ |
#define | PTRDIFFT 0x1000 /* t: ptrdiff_t */ |
#define | SIZET 0x2000 /* z: size_t */ |
#define | SHORTSHORT 0x4000 /** hh: char */ |
#define | SIGNOK 0x40 /* +/- is (still) legal */ |
#define | NDIGITS 0x80 /* no digits detected */ |
#define | DPTOK 0x100 /* (float) decimal point is still legal */ |
#define | EXPOK 0x200 /* (float) exponent (e+3, etc) still legal */ |
#define | PFXOK 0x100 /* 0x prefix is (still) legal */ |
#define | NZDIGITS 0x200 /* no zero digits detected */ |
#define | CT_CHAR 0 /* %c conversion */ |
#define | CT_CCL 1 /* %[...] conversion */ |
#define | CT_STRING 2 /* %s conversion */ |
#define | CT_INT 3 /* integer, i.e., strtoq or strtouq */ |
Typedefs | |
typedef u_quad_t(* | ccfntype) (const char *, char **, int) |
Functions | |
__FBSDID ("$FreeBSD$") | |
static const u_char * | __sccl (char *, const u_char *) |
int | sscanf (const char *ibuf, const char *fmt,...) |
int | vsscanf (const char *inp, char const *fmt0, va_list ap) |
#define BUF 32 /* Maximum length of numeric string. */ |
Definition at line 54 of file subr_scanf.c.
#define CT_CCL 1 /* %[...] conversion */ |
Definition at line 88 of file subr_scanf.c.
#define CT_CHAR 0 /* %c conversion */ |
Definition at line 87 of file subr_scanf.c.
#define CT_INT 3 /* integer, i.e., strtoq or strtouq */ |
Definition at line 90 of file subr_scanf.c.
#define CT_STRING 2 /* %s conversion */ |
Definition at line 89 of file subr_scanf.c.
#define DPTOK 0x100 /* (float) decimal point is still legal */ |
Definition at line 78 of file subr_scanf.c.
#define EXPOK 0x200 /* (float) exponent (e+3, etc) still legal */ |
Definition at line 79 of file subr_scanf.c.
#define INTMAXT 0x800 /* j: intmax_t */ |
Definition at line 65 of file subr_scanf.c.
#define LONG 0x01 /* l: long or double */ |
Definition at line 59 of file subr_scanf.c.
#define NDIGITS 0x80 /* no digits detected */ |
Definition at line 76 of file subr_scanf.c.
#define NOSKIP 0x20 /* do not skip blanks */ |
Definition at line 63 of file subr_scanf.c.
#define NZDIGITS 0x200 /* no zero digits detected */ |
Definition at line 82 of file subr_scanf.c.
#define PFXOK 0x100 /* 0x prefix is (still) legal */ |
Definition at line 81 of file subr_scanf.c.
#define POINTER 0x10 /* weird %p pointer (`fake hex') */ |
Definition at line 62 of file subr_scanf.c.
#define PTRDIFFT 0x1000 /* t: ptrdiff_t */ |
Definition at line 66 of file subr_scanf.c.
#define QUAD 0x400 |
Definition at line 64 of file subr_scanf.c.
#define SHORT 0x04 /* h: short */ |
Definition at line 60 of file subr_scanf.c.
#define SHORTSHORT 0x4000 /** hh: char */ |
Definition at line 68 of file subr_scanf.c.
#define SIGNOK 0x40 /* +/- is (still) legal */ |
Definition at line 75 of file subr_scanf.c.
#define SIZET 0x2000 /* z: size_t */ |
Definition at line 67 of file subr_scanf.c.
#define SUPPRESS 0x08 /* suppress assignment */ |
Definition at line 61 of file subr_scanf.c.
typedef u_quad_t(* ccfntype) (const char *, char **, int) |
Definition at line 91 of file subr_scanf.c.
__FBSDID | ( | "$FreeBSD$" | ) |
|
static |
Definition at line 581 of file subr_scanf.c.
Referenced by vsscanf().
int sscanf | ( | const char * | ibuf, |
const char * | fmt, | ||
... | |||
) |
Definition at line 96 of file subr_scanf.c.
References vsscanf().
Referenced by bitset_strscan(), kern_unmount(), res_find(), stats_tpl_sample_rates(), sysctl_handle_domainset(), and validate_uuid().
int vsscanf | ( | const char * | inp, |
char const * | fmt0, | ||
va_list | ap | ||
) |
Definition at line 108 of file subr_scanf.c.
References __sccl(), BUF, buf, CT_CCL, CT_CHAR, CT_INT, CT_STRING, flags, INTMAXT, LONG, NDIGITS, NOSKIP, NZDIGITS, PFXOK, PTRDIFFT, QUAD, res, SHORT, SHORTSHORT, SIGNOK, SIZET, and SUPPRESS.
Referenced by sscanf(), and vfs_scanopt().