You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by "Michael Glavassevich (JIRA)" <xe...@xml.apache.org> on 2006/09/09 00:21:23 UTC
[jira] Resolved: (XERCESJ-552) java.lang.StackOverflow when
validating an attribute using regular expression in xml schema
[ http://issues.apache.org/jira/browse/XERCESJ-552?page=all ]
Michael Glavassevich resolved XERCESJ-552.
------------------------------------------
Resolution: Duplicate
Assignee: (was: Xerces-J Developers Mailing List)
Duplicate of XERCESJ-589.
> java.lang.StackOverflow when validating an attribute using regular expression in xml schema
> -------------------------------------------------------------------------------------------
>
> Key: XERCESJ-552
> URL: http://issues.apache.org/jira/browse/XERCESJ-552
> Project: Xerces2-J
> Issue Type: Bug
> Components: XML Schema Structures
> Affects Versions: 2.2.1
> Environment: Operating System: Windows NT/2K
> Platform: PC
> Reporter: Ori
>
> I perform a SAX parsing on an XML file using an (external) validating schema
> (xsd file). During parsing I get the following error:
> java.lang.StackOverflowError
> at java.lang.String.charAt(String.java:454)
> at org.apache.xerces.impl.xpath.regex.RegularExpression.matchString
> (RegularExpression.java:1701)
> at org.apache.xerces.impl.xpath.regex.RegularExpression.matchString
> (RegularExpression.java:1940)
> at org.apache.xerces.impl.xpath.regex.RegularExpression.matchString
> (RegularExpression.java:1914)
> at org.apache.xerces.impl.xpath.regex.RegularExpression.matchString
> (RegularExpression.java:1940)
> at org.apache.xerces.impl.xpath.regex.RegularExpression.matchString
> (RegularExpression.java:1914)
> at org.apache.xerces.impl.xpath.regex.RegularExpression.matchString
> (RegularExpression.java:1940)
> at org.apache.xerces.impl.xpath.regex.RegularExpression.matchString
> (RegularExpression.java:1914)
> ....
> I tried to debug a little and saw that the problem is caused with a specific
> value which is 1719 characters long.
> The regular expression from my xsd file is:
> <xsd:pattern value="(\{[^}|"<>]+\})?\i\c*\|([^\\]|\\\\|\\\|)
> *\|"/>
> (legal expressions are for example: "|abc|def|" or "|ab\\c|def|")
> The value it tries to evaluate:
> Books_prod_info|100553088|103872294|This is "an account of of the domestic
> life of Samuel Clemens. . . . Willis discusses Olivia's role as reformer
> of her husband's lifestyle and editor of his work She also writes . . .
> about Olivia's role in the education of her children, the individual
> aspirations and problems of each child, and theirrelationships with their
> parents." (Am Lit) Bibliography. Index. Mark Twain is America's best-
> known and perhaps most popular writer. But until now little has been known
> about the love of his life--Olivia Langdon Clemens, his adored
> "Livy". In Mark and Livy, Resa Willis has redressed this oversight,
> presenting us with the fullest insights and details of four decades of
> courtship and marriage, showing us a famous writer at home and at work, and the
> splendid woman who was his consistent critic and companion, editor and muse,
> trusted advisor and beloved wife. The daughter of a prominent, wealthy, and
> broad-minded family--they were founding members of the local Congregational
> Church, abolitionists, and helpers on the underground railroad--in upstate New
> York, Olivia Langdon was just twenty-two when she and Samuel Clemens first met
> at Christmastime in 1867. (In his autobiography, he would later claim that he
> had seen her before--in a photograph owned by her brother, whom Clemens had
> befriended on his trip to the Holy Land--and fallen in love at first sight.) A
> lifelong diarist, reader, and commentator on her own readings, Livy at first
> resisted his courtship, but soon she relented, providing Clemens with the
> "sivilizing" influence that he craved, even as he thought himself
> unworthy, and that made life possible for him as he composed the books that
> made his fortune and reputation. |27|||
> Thanks a lot.
> And if you need my xml file and my schema file - I have it (I didn't see any
> way to submit them using bugzilla).
> Ori.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: j-dev-unsubscribe@xerces.apache.org
For additional commands, e-mail: j-dev-help@xerces.apache.org