mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-22 15:49:53 +01:00
Removed redundant padding check.
This commit is contained in:
@@ -119,10 +119,6 @@ implements ConnectionReader {
|
|||||||
int read = in.read(payload, offset,
|
int read = in.read(payload, offset,
|
||||||
payloadLen + paddingLen - offset);
|
payloadLen + paddingLen - offset);
|
||||||
if(read == -1) throw new EOFException(); // Unexpected EOF
|
if(read == -1) throw new EOFException(); // Unexpected EOF
|
||||||
// The padding must be set to zero
|
|
||||||
for(int i = offset; i < offset + read; i++) {
|
|
||||||
if(payload[i] != 0) throw new FormatException();
|
|
||||||
}
|
|
||||||
mac.update(payload, offset, read);
|
mac.update(payload, offset, read);
|
||||||
offset += read;
|
offset += read;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user