Changeset 9eb3cc5 for apps


Ignore:
Timestamp:
May 25, 2018 7:39:22 PM (2 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
c1b9aa9
Parents:
2fab97f
Message:

i2ptunnel: Fix dup tunnels clicking generate on new tunnel (ticket #2225)
remove dup call to processAction()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • apps/i2ptunnel/java/src/net/i2p/i2ptunnel/web/IndexBean.java

    r2fab97f r9eb3cc5  
    268268    }
    269269   
     270    /**
     271     * Only call this ONCE! Or you will get duplicate tunnels on save.
     272     *
     273     * @return not HTML escaped, or "" if empty
     274     */
    270275    private String saveChanges() {
    271276        // FIXME name will be HTML escaped twice
     
    301306                String result = processAction();
    302307                if (result.length() > 0)
    303                     buf.append(processAction()).append('\n');
     308                    buf.append(result).append('\n');
    304309            } catch (RuntimeException e) {
    305310                _log.log(Log.CRIT, "Error processing " + _action, e);
     
    12091214    private String generateNewEncryptionKey() {
    12101215        TunnelController tun = getController(_tunnel);
    1211         Properties config = getConfig();
    12121216        if (tun == null) {
    12131217            // creating new
    1214             tun = new TunnelController(config, "", true);
    1215             _group.addController(tun);
    1216             saveChanges();
    12171218        } else if (tun.getIsRunning() || tun.getIsStarting()) {
    12181219            return "Tunnel must be stopped before modifying leaseset encryption key";
Note: See TracChangeset for help on using the changeset viewer.