#JC-1198. Fixing too big page number when offset overflows MAXINT