Added sanity check for num pages/frames