From 9dd5451e9facd1a354847c2d58d843a5610675f9 Mon Sep 17 00:00:00 2001 From: tdurieux Date: Tue, 7 Mar 2017 13:25:46 +0100 Subject: [PATCH] fixed files form Lang #9 --- .../Lang/9/org/apache/commons/lang3/time/FastDateParser.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/projects/Lang/9/org/apache/commons/lang3/time/FastDateParser.java b/projects/Lang/9/org/apache/commons/lang3/time/FastDateParser.java index 8df302f..38857c7 100644 --- a/projects/Lang/9/org/apache/commons/lang3/time/FastDateParser.java +++ b/projects/Lang/9/org/apache/commons/lang3/time/FastDateParser.java @@ -141,6 +141,9 @@ private void init() { currentFormatField= nextFormatField; currentStrategy= nextStrategy; } + if (patternMatcher.regionStart() != patternMatcher.regionEnd()) { + throw new IllegalArgumentException("Failed to parse \""+pattern+"\" ; gave up at index "+patternMatcher.regionStart()); + } if(currentStrategy.addRegex(this, regex)) { collector.add(currentStrategy); }