I2P Address: [http://git.idk.i2p]

Skip to content
Snippets Groups Projects
Commit 83ccfb45 authored by zzz's avatar zzz
Browse files

* i2psnark: Fix NPE when fetching invalid torrent (ticket #1307)

parent e9688289
No related branches found
No related tags found
No related merge requests found
......@@ -178,7 +178,10 @@ public class FetchAndAdd extends Snark implements EepGet.StatusListener, Runnabl
// This may take a LONG time to create the storage.
_mgr.copyAndAddTorrent(file, canonical);
snark = _mgr.getTorrentByBaseName(originalName);
snark.startTorrent();
if (snark != null)
snark.startTorrent();
else
throw new IOException("Unknown error - check logs");
}
} catch (IOException ioe) {
_mgr.addMessage(_("Torrent at {0} was not valid", urlify(_url)) + ": " + ioe.getMessage());
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment