Fix little-endian off-by-one bug in CheckPageFlag