Fix incorrect layout of data in the groupdata heap.

Arrays were double-counting their array-ness when incrementing the
offsets. I'm not sure why this didn't fail much more spectacularly
and frequently.

I will backport to 1.4.