Changeset 7294 in josm


Ignore:
Timestamp:
2014-07-07T22:44:23+02:00 (10 years ago)
Author:
Don-vip
Message:

fix #10242 - catch NoClassDefFoundError when ClassNotFoundException is catched

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

Legend:

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

    r7185 r7294  
    790790                UIManager.setLookAndFeel(laf);
    791791            }
    792             catch (final ClassNotFoundException e) {
     792            catch (final NoClassDefFoundError | ClassNotFoundException e) {
    793793                info("Look and Feel not found: " + laf);
    794794                Main.pref.put("laf", defaultlaf);
  • trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/MapRendererFactory.java

    r7005 r7294  
    102102            try {
    103103                return Class.forName(className, true, cl);
    104             } catch (final ClassNotFoundException e) {
    105                 // ignore
     104            } catch (final NoClassDefFoundError | ClassNotFoundException e) {
     105                Main.trace(e.getMessage());
    106106            }
    107107        }
  • trunk/src/org/openstreetmap/josm/data/projection/datum/NTV2Util.java

    r6362 r7294  
    114114            Class.forName("java.nio.channels.FileChannel");
    115115            nioAvailable = true;
    116         } catch (ClassNotFoundException cnfe) {
     116        } catch (NoClassDefFoundError | ClassNotFoundException cnfe) {
    117117            Main.info(cnfe.getMessage());
    118118        }
  • trunk/src/org/openstreetmap/josm/plugins/PluginInformation.java

    r7033 r7294  
    333333        try {
    334334            return Class.forName(className, true, classLoader);
    335         } catch (ClassNotFoundException | ClassCastException e) {
     335        } catch (NoClassDefFoundError | ClassNotFoundException | ClassCastException e) {
    336336            throw new PluginException(name, e);
    337337        }
Note: See TracChangeset for help on using the changeset viewer.