- strcpy (new->name, old->name);
-
- new->vars = xnmalloc (old->var_cnt, sizeof *new->vars);
- new->var_cnt = old->var_cnt;
- for (i = 0; i < new->var_cnt; i++)
+ new->name = xstrdup (old->name);
+ new->vars = xnmalloc (old->n_vars, sizeof *new->vars);
+ new->n_vars = old->n_vars;
+ for (i = 0; i < new->n_vars; i++)