Switch back to storing an index into the array of page locks rather than a direct pointer.

Backs out part of 64f087c3ab98f48924d03de0f532ef723b6430ce.