Changeset 15920 in josm


Ignore:
Timestamp:
2020-02-24T21:00:34+01:00 (5 years ago)
Author:
simon04
Message:

fix #18764, see #14088 - NPE in findIcon when adding a tag (patch by taylor.smock, extended)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/mappaint/mapcss/Selector.java

    r15910 r15920  
    379379        private void visitBBox(Environment e, AbstractFinder finder) {
    380380            boolean withNodes = finder instanceof ContainsFinder;
    381             if (left instanceof OptimizedGeneralSelector) {
     381            if (e.osm.getDataSet() == null) {
     382                // do nothing
     383            } else if (left instanceof OptimizedGeneralSelector) {
    382384                if (withNodes && ((OptimizedGeneralSelector) left).matchesBase(OsmPrimitiveType.NODE)) {
    383385                    finder.visit(e.osm.getDataSet().searchNodes(e.osm.getBBox()));
     
    438440                e.parent = e.osm;
    439441                if (right instanceof OptimizedGeneralSelector
     442                        && e.osm.getDataSet() != null
    440443                        && ((OptimizedGeneralSelector) right).matchesBase(OsmPrimitiveType.WAY)) {
    441444                    final CrossingFinder crossingFinder = new CrossingFinder(e);
Note: See TracChangeset for help on using the changeset viewer.