You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've come across a few XML documents that seems to stop my program in its tracks. I've traced the issue down to an issue with the decoding of many reference characters in a single attribute value.
For example, take the following example XML with 35 references:
As is, it takes over 9 minutes to parse on my machine. Decreasing to 34 <, it takes 4.8 minutes, while increasing to 36 gives a parse time of 17.5 minutes. My guess is that this is due to a "catastrophic backtracking" RegExp.
Interestingly, self-closing the <a> tag makes things work at a normal / expected speed.
I've come across a few XML documents that seems to stop my program in its tracks. I've traced the issue down to an issue with the decoding of many reference characters in a single attribute value.
For example, take the following example XML with 35 references:
As is, it takes over 9 minutes to
parse
on my machine. Decreasing to 34<
, it takes 4.8 minutes, while increasing to 36 gives a parse time of 17.5 minutes. My guess is that this is due to a "catastrophic backtracking" RegExp.Interestingly, self-closing the
<a>
tag makes things work at a normal / expected speed.The text was updated successfully, but these errors were encountered: