Skip to content

Commit

Permalink
Merge pull request #150 from clue-labs/php7.4
Browse files Browse the repository at this point in the history
Avoid unneeded warning when decoding invalid data on PHP 7.4
  • Loading branch information
jsor authored Jan 13, 2020
2 parents e41c74d + c24f511 commit d753b10
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ php:
- 7.0
- 7.1
- 7.2
- 7.3
- 7.4
- nightly # ignore errors, see below
- hhvm # ignore errors, see below

Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
},
"require-dev": {
"clue/block-react": "^1.2",
"phpunit/phpunit": "^6.4 || ^5.7 || ^4.8.35",
"phpunit/phpunit": "^7.0 || ^6.4 || ^5.7 || ^4.8.35",
"react/promise-stream": "^1.1"
},
"autoload": {
Expand Down
1 change: 0 additions & 1 deletion phpunit.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="false"
syntaxCheck="false"
bootstrap="tests/bootstrap.php"
>
<testsuites>
Expand Down
2 changes: 1 addition & 1 deletion src/ChunkedStreamDecoder.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ protected function iterateBuffer()
}
}
$this->nextChunkIsLength = false;
if (dechex(hexdec($lengthChunk)) !== strtolower($lengthChunk)) {
if (dechex(@hexdec($lengthChunk)) !== strtolower($lengthChunk)) {
$this->emit('error', array(
new Exception('Unable to validate "' . $lengthChunk . '" as chunk length header'),
));
Expand Down

0 comments on commit d753b10

Please sign in to comment.