Browse Source

fix a bug in cyclic dependent rules.

afl-fuzzing
Roker 3 years ago
parent
commit
f0bb7db6c0
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      src/parse_timestamp.cc

+ 2
- 2
src/parse_timestamp.cc View File

@ -60,7 +60,7 @@ const Rule qp = qi::lit('\\') >> (vchar | ws); // quoted pair
// Comments
const Rule ctext = qi::omit[ qi::char_ - qi::char_("()\\") ];
const Rule ccontent = ctext | qp | comment;
const Rule ccontent = ctext | qp | comment.alias();
const Rule comment = qi::lit('(') >> *(ws | ccontent) >> -ws >> qi::lit(')');
const Rule cfws = qi::omit[ ( +(+ws >> comment >> +ws)) | ws ];
@ -180,7 +180,7 @@ timestamp* parse_timestamp(const std::string& s)
{ "Thu, 20 Oct 1992 11:22:33 +0000",
"Sun, 20 Oct 1992 11:45:15 -0500" }, date_time, "DateTime" );
***/
std::cerr << " \n === TimeStamp \"" << s << "\" to parse...\n";
std::string::const_iterator begin = s.begin();
bool okay = qi::parse(begin, s.end(), date_time, *ts );
LOG << " \n === TimeStamp \"" << s << "\" is " << (okay?"okay":"NOT OKAY");


Loading…
Cancel
Save