MCPcopy Create free account
hub / github.com/apache/trafficserver / mime_parse_month

Function mime_parse_month

src/proxy/hdrs/MIME.cc:3546–3567  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3544}
3545
3546bool
3547mime_parse_month(const char *&buf, const char *end, int *month)
3548{
3549 const char *e;
3550
3551 while ((buf != end) && *buf && !ParseRules::is_alpha(*buf)) {
3552 buf += 1;
3553 }
3554
3555 e = buf;
3556 while ((e != end) && *e && ParseRules::is_alpha(*e)) {
3557 e += 1;
3558 }
3559
3560 *month = month_names_dfa->match({buf, size_t(e - buf)});
3561 if (*month < 0) {
3562 return false;
3563 } else {
3564 buf = e;
3565 return true;
3566 }
3567}
3568
3569bool
3570mime_parse_mday(const char *&buf, const char *end, int *mday)

Callers 1

mime_parse_dateFunction · 0.85

Calls 1

matchMethod · 0.45

Tested by

no test coverage detected