Switch from calloc() to malloc()+memset() to match the practices used