X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fmath%2Ftukey-hinges.c;fp=src%2Fmath%2Ftukey-hinges.c;h=b59b878ba64991c2bea385553e24c8e058ab8c2e;hb=922dfe227e0a157f895c025b8f8590e2bfc59f23;hp=aaf4881afa954e79e2a9b731188572072df1b558;hpb=947e6378c28a6a33a2cd9ef4c4d90e001bdcc359;p=pspp diff --git a/src/math/tukey-hinges.c b/src/math/tukey-hinges.c index aaf4881afa..b59b878ba6 100644 --- a/src/math/tukey-hinges.c +++ b/src/math/tukey-hinges.c @@ -64,10 +64,7 @@ static void destroy (struct statistic *s) { struct tukey_hinges *th = UP_CAST (s, struct tukey_hinges, parent.parent); - struct order_stats *os = &th->parent; - - free (os->k); - free (s); + free (th); }; struct tukey_hinges * @@ -81,7 +78,7 @@ tukey_hinges_create (double W, double c_min) assert (c_min >= 0); os->n_k = 3; - os->k = xcalloc (3, sizeof (*os->k)); + os->k = th->k; if (c_min >= 1.0) {