Changeset c3881a8 for router


Ignore:
Timestamp:
Aug 25, 2018 1:26:28 PM (23 months ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
57ddc8e
Parents:
ff551b1
Message:

fix deprecations

File:
1 edited

Legend:

Unmodified
Added
Removed
  • router/java/src/com/southernstorm/noise/protocol/Noise.java

    rff551b1 rc3881a8  
    126126        {
    127127                try {
     128                        // java since 1.7; android since API 19
    128129                        Class<?> c = Class.forName("javax.crypto.AEADBadTagException");
    129                         throw (BadPaddingException)(c.newInstance());
    130                 } catch (ClassNotFoundException e) {
    131                 } catch (InstantiationException e) {
    132                 } catch (IllegalAccessException e) {
     130                        throw (BadPaddingException)(c.getDeclaredConstructor().newInstance());
     131                } catch (Exception e) {
    133132                }
    134133                throw new BadPaddingException();
Note: See TracChangeset for help on using the changeset viewer.