DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23132>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23132 Perl5Util.match() hangs/loops in certain cases Summary: Perl5Util.match() hangs/loops in certain cases Product: ORO Version: 2.0.7 Platform: PC OS/Version: Windows NT/2K Status: NEW Severity: Major Priority: Other Component: Main AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] Hi! I use Perl5Util.match() to validate email addresses. For .co.uk addresses that lack an @, using the regular expression pattern, "^(\\w+[-_.'&\\/]*)+@(\\w+[- _.])+\\w+$", the call to match() takes about 20 mins to return on a quad CPU server (during which time the CPUs are very busy). Here is some demonstration code. I experience this problem on version 2.0.6 and 2.0.7 Many thanks, Louis Joubert ------------------- import org.apache.oro.text.perl.Perl5Util; public class TestPerlMatcher{ public static void main (String[] args){ Perl5Util _perlUtil = new Perl5Util(); String validationRE = "^(\\w+[-_.'&\\/]*)+@(\\w+[-_.])+\\w+$"; String[] addresses = {"[EMAIL PROTECTED]", "joe.bloggsblogger.com", "[EMAIL PROTECTED]", "joe.bloggsblogger.co.uk", "[EMAIL PROTECTED] mopers.co.uk", "craig.rendowekopekopemopers.co.uk"}; //only the latter fails for (int i=0; i<addresses.length; i++){ System.out.println("PerlMatcher returns, for email address "+addresses[i]+", "+_perlUtil.match("/" + validationRE + "/", addresses [i])); } } } --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
