Changeset 31592 in osm for applications/editors


Ignore:
Timestamp:
2015-10-04T22:19:48+02:00 (9 years ago)
Author:
simon04
Message:

JOSM/reverter: Fix IllegalStateException when the first+last node of a closed way is a conflict - fixes #josm11811

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/reverter/src/reverter/DataSetCommandMerger.java

    r30737 r31592  
    55import java.util.ArrayList;
    66import java.util.Collection;
     7import java.util.LinkedHashSet;
    78import java.util.LinkedList;
    89import java.util.List;
     
    9798        if (!source.isVisible()) return;
    9899        Way target = (Way)getMergeTarget(source);
    99        
    100         Collection<Conflict<OsmPrimitive>> localConflicts = new ArrayList<>();
     100
     101        // use a set to avoid conflicts being added twice for closed ways, fixes #11811
     102        Collection<Conflict<OsmPrimitive>> localConflicts = new LinkedHashSet<>();
    101103
    102104        List<Node> newNodes = new ArrayList<>(source.getNodesCount());
Note: See TracChangeset for help on using the changeset viewer.