Fix bug #58664
[pspp] / src / language / stats / median.c
index 9cba44dfd556bcd50db351cabb42db13be2a2dea..9c35c15a456aa54820a3faafaa847e5bbbcd3136 100644 (file)
@@ -118,7 +118,7 @@ median_execute (const struct dataset *ds,
   const bool n_sample_test = (value_compare_3way (&nst->val2, &nst->val1,
                                       var_get_width (nst->indep_var)) > 0);
 
-  struct results *results = xcalloc (nst->n_vars, sizeof (*results));
+  struct results *results = XCALLOC (nst->n_vars,  struct results);
   int n_vals = 0;
   for (v = 0; v < nst->n_vars; ++v)
     {