Use modern idiom for calloc() replacement.