Skip to content

Commit

Permalink
Loosen crc32 checksum comparison
Browse files Browse the repository at this point in the history
  • Loading branch information
jeskew committed Jun 25, 2015
1 parent 959ebde commit 4947d33
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Api/Parser/Crc32ValidatingParser.php
Expand Up @@ -28,7 +28,7 @@ public function __invoke(
) {
if ($expected = $response->getHeaderLine('x-amz-crc32')) {
$hash = hexdec(Psr7\hash($response->getBody(), 'crc32b'));
if ((int) $expected !== $hash) {
if ($expected != $hash) {
throw new AwsException(
"crc32 mismatch. Expected {$expected}, found {$hash}.",
$command,
Expand Down

0 comments on commit 4947d33

Please sign in to comment.