mirror of
https://github.com/square/okhttp.git
synced 2026-01-25 16:01:38 +03:00
Merge pull request #289 from levelup/double-negative
the numberOfPairs may not be negative when numberOfPairs*2 is negative
This commit is contained in:
@@ -281,7 +281,7 @@ final class Spdy3 implements Variant {
|
||||
this.compressedLimit += length;
|
||||
try {
|
||||
int numberOfPairs = nameValueBlockIn.readInt();
|
||||
if (numberOfPairs < 0) {
|
||||
if ((numberOfPairs * 2) < 0) {
|
||||
Logger.getLogger(getClass().getName()).warning("numberOfPairs < 0: " + numberOfPairs);
|
||||
throw ioException("numberOfPairs < 0");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user