Changeset 9734 in josm


Ignore:
Timestamp:
2016-02-04T09:38:26+01:00 (9 years ago)
Author:
Don-vip
Message:

fix NPE seen in unit tests

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/history/HistoryBrowserModel.java

    r9733 r9734  
    625625        if (latest == null) {
    626626            if (this.current == this.latest) {
    627                 this.current = history.getLatest();
     627                this.current = history != null ? history.getLatest() : null;
    628628            }
    629629            if (this.reference == this.latest) {
    630                 this.reference = history.getLatest();
     630                this.reference = history != null ? history.getLatest() : null;
    631631            }
    632632            this.latest = null;
     
    644644
    645645    /**
    646      * Removes this model as listener for data change and layer change
    647      * events.
     646     * Removes this model as listener for data change and layer change events.
    648647     *
    649648     */
Note: See TracChangeset for help on using the changeset viewer.