* UPnP:
- Change all log errors to warns (tickets #76, #95, #120) - Double socket soTimeout to 2 seconds
This commit is contained in:
@ -1,3 +1,10 @@
|
||||
2011-01-16 zzz
|
||||
* Console: Allow editing of console args
|
||||
* UDP: Prevent rare startup NPE
|
||||
* UPnP:
|
||||
- Change all log errors to warns (tickets #76, #95, #120)
|
||||
- Double socket soTimeout to 2 seconds
|
||||
|
||||
2011-01-15 zzz
|
||||
* Console: Add some HTTP headers in the view servlets
|
||||
|
||||
|
@ -18,10 +18,10 @@ public class RouterVersion {
|
||||
/** deprecated */
|
||||
public final static String ID = "Monotone";
|
||||
public final static String VERSION = CoreVersion.VERSION;
|
||||
public final static long BUILD = 11;
|
||||
public final static long BUILD = 12;
|
||||
|
||||
/** for example "-test" */
|
||||
public final static String EXTRA = "";
|
||||
public final static String EXTRA = "-rc";
|
||||
public final static String FULL_VERSION = VERSION + "-" + BUILD + EXTRA;
|
||||
public static void main(String args[]) {
|
||||
System.out.println("I2P Router version: " + FULL_VERSION);
|
||||
|
@ -388,10 +388,10 @@ public class HTTPRequest extends HTTPPacket
|
||||
// Set the timeout to be nice and short, the device should be local and fast.
|
||||
// Yeah, the UPnP standard is a minute or something, too bad.
|
||||
// If he can't get back to us in a few seconds, forget it.
|
||||
// And set the soTimeout to 1 second (for reads).
|
||||
// And set the soTimeout to 2 second (for reads).
|
||||
//postSocket = new Socket(host, port);
|
||||
postSocket = new Socket();
|
||||
postSocket.setSoTimeout(1000);
|
||||
postSocket.setSoTimeout(2000);
|
||||
SocketAddress sa = new InetSocketAddress(host, port);
|
||||
postSocket.connect(sa, 3000);
|
||||
}
|
||||
|
@ -52,14 +52,14 @@ public final class Debug
|
||||
}
|
||||
public static final void warning(String s) {
|
||||
if (_log != null)
|
||||
_log.error(s);
|
||||
_log.warn(s);
|
||||
}
|
||||
public static final void warning(String m, Exception e) {
|
||||
if (_log != null)
|
||||
_log.error(m, e);
|
||||
_log.warn(m, e);
|
||||
}
|
||||
public static final void warning(Exception e) {
|
||||
if (_log != null)
|
||||
_log.error("", e);
|
||||
_log.warn("", e);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user