Ignore:
Timestamp:
2016-12-14T15:50:53+01:00 (2 years ago)
Author:
Don-vip
Message:

sonar - squid:S2259 - Null pointers should not be dereferenced

File:
1 edited

Legend:

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

    r11322 r11397  
    425425            switch (column) {
    426426            case VersionTableColumnModel.COL_VERSION:
    427                 return Long.toString(getPrimitive(row).getVersion());
     427                HistoryOsmPrimitive p1 = getPrimitive(row);
     428                if (p1 != null)
     429                    return Long.toString(p1.getVersion());
     430                return null;
    428431            case VersionTableColumnModel.COL_REFERENCE:
    429432                return isReferencePointInTime(row);
Note: See TracChangeset for help on using the changeset viewer.