I think it'd be better to remove the manual overwriting of each element, and leave the memset.