1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-07-29 11:41:22 +03:00

559410 - Regexp bug on (...)? constructs

* xmlregexp.c: fix a regexp bug on some (...)? constructs
* test/schemas/nvdcve* result/schemas/nvdcve*: add the tests to the
  regression suite
This commit is contained in:
Daniel Veillard
2009-08-22 18:56:01 +02:00
parent db4ac221f0
commit d80d0728bf
5 changed files with 5741 additions and 2 deletions

View File

@ -1569,8 +1569,13 @@ xmlFAGenerateTransitions(xmlRegParserCtxtPtr ctxt, xmlRegStatePtr from,
* 1. set transition from atom start to new state
* 2. set transition from atom end to this state.
*/
xmlFAGenerateEpsilonTransition(ctxt, atom->start, 0);
xmlFAGenerateEpsilonTransition(ctxt, atom->stop, ctxt->state);
if (to == NULL) {
xmlFAGenerateEpsilonTransition(ctxt, atom->start, 0);
xmlFAGenerateEpsilonTransition(ctxt, atom->stop,
ctxt->state);
} else {
xmlFAGenerateEpsilonTransition(ctxt, atom->start, to);
}
break;
case XML_REGEXP_QUANT_MULT:
atom->quant = XML_REGEXP_QUANT_ONCE;