Changes from -rc diff review

This commit is contained in:
str4d
2013-11-28 11:10:57 +00:00
parent c0ef19a281
commit 707f616498
22 changed files with 35 additions and 79 deletions

View File

@ -5,7 +5,6 @@ import java.io.File;
import java.io.IOException;
import java.util.Collections;
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Properties;
@ -216,10 +215,8 @@ public class I2PSnarkUtil {
_log.debug("Connecting to I2P", new Exception("I did it"));
Properties opts = _context.getProperties();
if (_opts != null) {
for (Iterator<String> iter = _opts.keySet().iterator(); iter.hasNext(); ) {
String key = iter.next();
opts.setProperty(key, _opts.get(key).toString());
}
for (Map.Entry<String, String> entry : _opts.entrySet() )
opts.setProperty(entry.getKey(), entry.getValue());
}
if (opts.getProperty("inbound.nickname") == null)
opts.setProperty("inbound.nickname", _baseName.replace("i2psnark", "I2PSnark"));

View File

@ -14,7 +14,6 @@ import java.util.Collections;
import java.util.Comparator;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Properties;
@ -1687,8 +1686,7 @@ public class SnarkManager implements CompleteListener {
// Don't remove magnet torrents that don't have a torrent file yet
existingNames.removeAll(_magnets);
// now lets see which ones have been removed...
for (Iterator<String> iter = existingNames.iterator(); iter.hasNext(); ) {
String name = iter.next();
for (String name : existingNames) {
if (foundNames.contains(name)) {
// known and still there. noop
} else {