fix #7515, sizeof(::BitArray). this should match read and write.