Changeset 7786 in josm for trunk/src


Ignore:
Timestamp:
2014-12-10T23:36:01+01:00 (10 years ago)
Author:
Don-vip
Message:

see #10816 - fix text parsing regressions

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/tools/TextTagParser.java

    r7783 r7786  
    204204        // Format
    205205        // tag1\tval1\ntag2\tval2\n
    206         tags = readTagsByRegexp(buf, "[\\r\\n]+", "([a-zA-Z0-9:_]+)\\t(.*?)", false);
     206        tags = readTagsByRegexp(buf, "[\\r\\n]+", ".*([a-zA-Z0-9:_]+).*\\t(.*?)", false);
    207207                // try "tag\tvalue\n" format
    208208        if (tags!=null) return tags;
     
    213213        // a = "b=c" is OK
    214214        // a = b=c  - this method of parsing fails intentionally
    215         tags = readTagsByRegexp(buf, "[\\n\\t\\r]+", "([a-zA-Z0-9:_]+)=(.*?)", true);
     215        tags = readTagsByRegexp(buf, "[\\n\\t\\r]+", "(.*?)=(.*?)", true);
    216216                // try format  t1=v1\n t2=v2\n ...
    217217        if (tags!=null) return tags;
Note: See TracChangeset for help on using the changeset viewer.