Aren't the slots being intialized from the original index? I wouldn't be surprised if I'm wrong - I'm often out by an indirection when staring at this code..

To make sure I understand.. Is this code complex because we're avoiding saving one memory allocation by combining the allocation for the WT_PAGE_INDEX structure and the array of refs it references?