mirror of
https://github.com/i2p/i2p.i2p.git
synced 2026-10-22 17:32:28 +00:00
I2CP: Length check exception message improvement
This commit is contained in:
2 files changed
+2
-2
No files matched your search
@@ -45,7 +45,7 @@ public class I2CPMessageHandler {
|
||||
throw new IOException("Connection closed");
|
||||
}
|
||||
if (length > MAX_LENGTH)
|
||||
throw new I2CPMessageException("Invalid message length specified");
|
||||
throw new I2CPMessageException("Invalid message length: " + length);
|
||||
int type = in.read();
|
||||
if (type < 0)
|
||||
throw new EOFException();
|
||||
|
||||
@@ -42,7 +42,7 @@ public abstract class I2CPMessageImpl implements I2CPMessage {
|
||||
throw new I2CPMessageException("Error reading the length bytes", dfe);
|
||||
}
|
||||
if (length > I2CPMessageHandler.MAX_LENGTH)
|
||||
throw new I2CPMessageException("Invalid message length specified");
|
||||
throw new I2CPMessageException("Invalid message length: " + length);
|
||||
int type = in.read();
|
||||
if (type < 0)
|
||||
throw new EOFException();
|
||||
|
||||
Reference in new issue
Block a user