fix struct array bug