Changeset 9774 in josm for trunk/src/org/openstreetmap


Ignore:
Timestamp:
2016-02-10T00:41:16+01:00 (9 years ago)
Author:
Don-vip
Message:

fix coverity (1350239, 1350240, 1350241) defects corresponding to Findbugs serialization warnings

Location:
trunk/src/org/openstreetmap/josm
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/osm/MultipolygonBuilder.java

    r9623 r9774  
    66import java.awt.Rectangle;
    77import java.awt.geom.Area;
     8import java.io.IOException;
     9import java.io.ObjectInputStream;
     10import java.io.ObjectOutputStream;
    811import java.util.ArrayList;
    912import java.util.Collection;
     
    308311    private static class Worker extends RecursiveTask<List<PolygonLevel>> {
    309312
     313        // Needed for Findbugs / Coverity because parent class is serializable
     314        private static final long serialVersionUID = 1L;
     315
    310316        private final transient List<JoinedPolygon> input;
    311317        private final int from;
     
    403409            return output;
    404410        }
     411
     412        private void readObject(ObjectInputStream ois) throws ClassNotFoundException, IOException {
     413            // Needed for Findbugs / Coverity because parent class is serializable
     414            ois.defaultReadObject();
     415        }
     416
     417        private void writeObject(ObjectOutputStream oos) throws IOException {
     418            // Needed for Findbugs / Coverity because parent class is serializable
     419            oos.defaultWriteObject();
     420        }
    405421    }
    406422}
  • trunk/src/org/openstreetmap/josm/gui/dialogs/RelationListDialog.java

    r9668 r9774  
    124124    private final transient HighlightHelper highlightHelper = new HighlightHelper();
    125125    private final boolean highlightEnabled = Main.pref.getBoolean("draw.target-highlight", true);
    126     private RecentRelationsAction recentRelationsAction;
     126    private transient RecentRelationsAction recentRelationsAction;
    127127
    128128    /**
Note: See TracChangeset for help on using the changeset viewer.