From 67d7ae3073a16f13e50ba383c29aed24dc0b2ce8 Mon Sep 17 00:00:00 2001 From: Samuel Tardieu Date: Tue, 18 Oct 2011 21:57:53 +0200 Subject: Add three extra FIXME in parsing code --- main/src/cgeo/geocaching/cgBase.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/main/src/cgeo/geocaching/cgBase.java b/main/src/cgeo/geocaching/cgBase.java index 0615c0f..ca82bb0 100644 --- a/main/src/cgeo/geocaching/cgBase.java +++ b/main/src/cgeo/geocaching/cgBase.java @@ -692,9 +692,14 @@ public class cgBase { String inventoryPre = null; // GC* code + // FIXME: most of the blocks below cannot raise any exception try { final Matcher matcherCode = patternCode.matcher(row); + // FIXME: what are those while loops that can erase the previous values? This should either be fixed + // or documented here. while (matcherCode.find()) { + // FIXME: here, and probably below, a find necessarily has a group count > 0 as the first group + // is not optional. if (matcherCode.groupCount() > 0) { // The String constructor is necessary as long as the pattern matching doesn't use the // methods from BaseUtil. Otherwise every geocode holds the complete page in memory -- cgit v1.1