enum format_type {
FORMAT_TYPE_NONE, /* Just a string part */
- FORMAT_TYPE_WITDH,
+ FORMAT_TYPE_WIDTH,
FORMAT_TYPE_PRECISION,
FORMAT_TYPE_CHAR,
FORMAT_TYPE_STR,
const char *start = fmt;
/* we finished early by reading the field width */
- if (spec->type == FORMAT_TYPE_WITDH) {
+ if (spec->type == FORMAT_TYPE_WIDTH) {
if (spec->field_width < 0) {
spec->field_width = -spec->field_width;
spec->flags |= LEFT;
spec->field_width = skip_atoi(&fmt);
else if (*fmt == '*') {
/* it's the next argument */
- spec->type = FORMAT_TYPE_WITDH;
+ spec->type = FORMAT_TYPE_WIDTH;
return ++fmt - start;
}
break;
}
- case FORMAT_TYPE_WITDH:
+ case FORMAT_TYPE_WIDTH:
spec.field_width = va_arg(args, int);
break;
case FORMAT_TYPE_NONE:
break;
- case FORMAT_TYPE_WITDH:
+ case FORMAT_TYPE_WIDTH:
case FORMAT_TYPE_PRECISION:
save_arg(int);
break;
break;
}
- case FORMAT_TYPE_WITDH:
+ case FORMAT_TYPE_WIDTH:
spec.field_width = get_arg(int);
break;