Changeset 17167 in josm for trunk/src/org


Ignore:
Timestamp:
2020-10-11T22:00:25+02:00 (4 years ago)
Author:
GerdP
Message:

see #19885: memory leak with "temporary" objects in validator and actions
revert changes in JoinAreasAction made in r16048. Can't use ChangePropertyCommand to remove all tags

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/actions/JoinAreasAction.java

    r17163 r17167  
    2828import org.openstreetmap.josm.command.ChangeCommand;
    2929import org.openstreetmap.josm.command.ChangeNodesCommand;
    30 import org.openstreetmap.josm.command.ChangePropertyCommand;
    3130import org.openstreetmap.josm.command.Command;
    3231import org.openstreetmap.josm.command.DeleteCommand;
     
    17201719    private void stripTags(Collection<Way> ways) {
    17211720        for (Way w : ways) {
    1722             cmds.add(new ChangePropertyCommand(Collections.singleton(w), Collections.emptyMap()));
     1721            final Way wayWithoutTags = new Way(w);
     1722            wayWithoutTags.removeAll();
     1723            cmds.add(new ChangeCommand(w, wayWithoutTags));
    17231724        }
    17241725        /* I18N: current action printed in status display */
Note: See TracChangeset for help on using the changeset viewer.