Changeset 11873 in josm


Ignore:
Timestamp:
2017-04-09T17:17:09+02:00 (8 years ago)
Author:
Don-vip
Message:

findbugs - NP_NULL_ON_SOME_PATH_FROM_RETURN_VALUE

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/preferences/imagery/CommonSettingsPanel.java

    r11810 r11873  
    118118        File[] cacheFiles = directory.listFiles((FilenameFilter) (dir, name) -> name.endsWith(".data") || name.endsWith(".key"));
    119119        JCSCacheManager.shutdown(); // shutdown Cache - so files can by safely deleted
    120         for (File cacheFile: cacheFiles) {
    121             Utils.deleteFile(cacheFile);
     120        if (cacheFiles != null) {
     121            for (File cacheFile: cacheFiles) {
     122                Utils.deleteFile(cacheFile);
     123            }
    122124        }
    123125    }
Note: See TracChangeset for help on using the changeset viewer.