Skip to content

Commit

Permalink
Force little endian byte order for MMDB
Browse files Browse the repository at this point in the history
  • Loading branch information
Nadyita committed Jan 9, 2025
1 parent a354cea commit 9b452fb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/MMDB/AsyncMMDBClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ private function readLong(): int {
if ($packed === null || strlen($packed) < 4) {
throw new \Exception('The MMDB file is broken');
}
$unpacked = unpack('L', $packed);
$unpacked = unpack('V', $packed);
return array_pop($unpacked);
}

Expand Down

0 comments on commit 9b452fb

Please sign in to comment.