Changeset 4f9c442


Ignore:
Timestamp:
Oct 24, 2010 4:56:43 PM (9 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
ac3e6e2
Parents:
adab0cc
Message:

fix disconnect race NPE

File:
1 edited

Legend:

Unmodified
Added
Removed
  • apps/i2psnark/java/src/org/klomp/snark/I2PSnarkUtil.java

    radab0cc r4f9c442  
    191191    public void disconnect() {
    192192        I2PSocketManager mgr = _manager;
     193        // FIXME this can cause race NPEs elsewhere
    193194        _manager = null;
    194195        _shitlist.clear();
     
    202203    /** connect to the given destination */
    203204    I2PSocket connect(PeerID peer) throws IOException {
     205        I2PSocketManager mgr = _manager;
     206        if (mgr == null)
     207            throw new IOException("No socket manager");
    204208        Destination addr = peer.getAddress();
    205209        if (addr == null)
Note: See TracChangeset for help on using the changeset viewer.