From: Jason Stover Date: Fri, 21 Sep 2007 20:48:14 +0000 (+0000) Subject: fix memory leaks; bug 21056 X-Git-Tag: v0.6.0~257 X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ce16a4a594e7ddfc277afc4abb7faaeb1a03d233;p=pspp-builds.git fix memory leaks; bug 21056 --- diff --git a/src/language/stats/ChangeLog b/src/language/stats/ChangeLog index 4f63f167..21e27f18 100644 --- a/src/language/stats/ChangeLog +++ b/src/language/stats/ChangeLog @@ -1,3 +1,8 @@ +2007-09-21 Jason Stover + + * regression.q (run_regression): Partial fix of memory leak, bug + 21056. + 2007-09-19 Ben Pfaff Fix bug #21108. diff --git a/src/language/stats/regression.q b/src/language/stats/regression.q index 0b7250ce..d923a35b 100644 --- a/src/language/stats/regression.q +++ b/src/language/stats/regression.q @@ -1199,8 +1199,6 @@ run_regression (struct casereader *input, struct cmd_regression *cmd, lopts.get_indep_mean_std[i] = 1; } models[k] = pspp_linreg_cache_alloc (X->m->size1, X->m->size2); - models[k]->indep_means = gsl_vector_alloc (X->m->size2); - models[k]->indep_std = gsl_vector_alloc (X->m->size2); models[k]->depvar = dep_var; /* For large data sets, use QR decomposition. diff --git a/src/math/linreg/ChangeLog b/src/math/linreg/ChangeLog index a45216fd..08ab1440 100644 --- a/src/math/linreg/ChangeLog +++ b/src/math/linreg/ChangeLog @@ -1,3 +1,8 @@ +2007-09-21 Jason Stover + + * linreg.c (pspp_linreg_cache_free): Partial fix of memory leak, + bug 21056. + 2007-08-11 Jason Stover * linreg.h (enum): Dropped ambiguous PSPP_LINREG_SVD in favor of diff --git a/src/math/linreg/linreg.c b/src/math/linreg/linreg.c index 3b5b50dd..4fc3b20a 100644 --- a/src/math/linreg/linreg.c +++ b/src/math/linreg/linreg.c @@ -189,6 +189,7 @@ pspp_linreg_cache_free (void *m) { pspp_coeff_free (c->coeff[i]); } + free (c->coeff); free (c); } return true;