I understand that I have given you very little to go on. I'm thinking that it's neither a network problem or a server problem because it always hangs on the same page. Even when I change the order in which I retrieve the pages, it still hangs on the same page. So, it seems like the problem is page-specific.
I also have a line immediately following my {Do something} block that let's me know that I've exited the match. On the pages where my code hangs, it never exits the {Do something} block.
On the time to match part, the match happens fairly quickly whether or not there are zero matches, one match, or multiple matches.
One thing I should probably have mentioned, but neglected to, is that I've been running this code for a while now (it runs automatically once a day). Whoever runs the website that I'm pulling from made some minor changes to the HTML, so I needed to go back and change my matching pattern. But, like I said, it matches fine on some web pages, but then hangs on others.
In reply to Re^2: Regex infinite loop?
by Ninth Prince
in thread Regex infinite loop?
by Ninth Prince
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |