forked from I2P_Developers/i2p.i2p
i2ptunnel: Fix NPE on proxy.i2p/add when no params
This commit is contained in:
@@ -127,6 +127,10 @@ public abstract class LocalHTTPServer {
|
||||
// Parameters are url, host, dest, nonce, and master | router | private.
|
||||
// Do the add and redirect.
|
||||
if (targetRequest.equals("/add")) {
|
||||
if (query == null) {
|
||||
out.write(ERR_ADD.getBytes("UTF-8"));
|
||||
return;
|
||||
}
|
||||
Map<String, String> opts = new HashMap<String, String>(8);
|
||||
// this only works if all keys are followed by =value
|
||||
StringTokenizer tok = new StringTokenizer(query, "=&;");
|
||||
|
Reference in New Issue
Block a user