Skip to content

Commit

Permalink
Merge pull request aws#654 from aws/hotfix/loose-crc32-comparison
Browse files Browse the repository at this point in the history
Loosen crc32 checksum comparison
  • Loading branch information
jeskew committed Jun 25, 2015
2 parents 959ebde + 4947d33 commit d17abb8
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 d17abb8

Please sign in to comment.