Changeset b2d72f9


Ignore:
Timestamp:
Jul 25, 2013 8:08:31 PM (7 years ago)
Author:
kytv <kytv@…>
Branches:
master
Children:
482787f
Parents:
19faa35 (diff), dd181a9 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

merge of '5ad8235a14f2f52799755969e5c877f4f1c159cc'

and 'f5d75b2ebc648c43182d685f30e96242e43caa69'

File:
1 edited

Legend:

Unmodified
Added
Removed
  • apps/streaming/java/src/net/i2p/client/streaming/PacketLocal.java

    r19faa35 rb2d72f9  
    3333    private final AtomicInteger _nackCount = new AtomicInteger(0);
    3434    private volatile boolean _retransmitted;
    35     private SimpleTimer2.TimedEvent _resendEvent;
     35    private volatile SimpleTimer2.TimedEvent _resendEvent;
    3636   
    3737    /** not bound to a connection */
     
    113113        _lastSend = _context.clock().now();
    114114    }
     115   
     116    private void cancelResend() {
     117        SimpleTimer2.TimedEvent ev = _resendEvent;
     118        if (ev != null)
     119            ev.cancel();
     120    }
     121   
    115122    public void ackReceived() {
    116123        final long now = _context.clock().now();
     
    121128            notifyAll();
    122129        }
    123         _resendEvent.cancel();
    124     }
     130        cancelResend();
     131    }
     132   
    125133    public void cancelled() {
    126134        synchronized (this) {
     
    129137            notifyAll();
    130138        }
    131         _resendEvent.cancel();
     139       cancelResend();
    132140        if (_log.shouldLog(Log.DEBUG))
    133141            _log.debug("Cancelled! " + toString(), new Exception("cancelled"));
Note: See TracChangeset for help on using the changeset viewer.