From: Jason Stover <jhs@math.gcsu.edu>
Date: Mon, 17 Apr 2006 16:29:36 +0000 (+0000)
Subject: pspp_linreg_cache_free returns a boolean
X-Git-Tag: sav-api~1978
X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e08ba3a0b4be7ebf4f049fa4ead1f0f1508bd7f8;p=pspp

pspp_linreg_cache_free returns a boolean
---

diff --git a/src/math/linreg/ChangeLog b/src/math/linreg/ChangeLog
index ca3a647cba..b35a381b8a 100644
--- a/src/math/linreg/ChangeLog
+++ b/src/math/linreg/ChangeLog
@@ -1,3 +1,7 @@
+2006-04-17  Jason Stover  <jhs@math.gcsu.edu>
+
+	* linreg.c (pspp_linreg_cache_free): Return a bool.
+
 Sat Apr 15 18:03:01 2006  Ben Pfaff  <blp@gnu.org>
 
 	* predict.c (pspp_linreg_predict): Change prototype to match
diff --git a/src/math/linreg/linreg.c b/src/math/linreg/linreg.c
index aeaa9b8dfd..3e29915769 100644
--- a/src/math/linreg/linreg.c
+++ b/src/math/linreg/linreg.c
@@ -121,7 +121,7 @@ pspp_linreg_cache_alloc (size_t n, size_t p)
   return c;
 }
 
-void
+bool
 pspp_linreg_cache_free (pspp_linreg_cache * c)
 {
   gsl_vector_free (c->indep_means);
@@ -130,6 +130,7 @@ pspp_linreg_cache_free (pspp_linreg_cache * c)
   gsl_matrix_free (c->cov);
   pspp_linreg_coeff_free (c->coeff);
   free (c);
+  return true;
 }
 
 /*
diff --git a/src/math/linreg/linreg.h b/src/math/linreg/linreg.h
index 727d764c65..67a422ea3f 100644
--- a/src/math/linreg/linreg.h
+++ b/src/math/linreg/linreg.h
@@ -20,7 +20,7 @@
 
 #ifndef LINREG_H
 #define LINREG_H
-
+#include <stdbool.h>
 #include <gsl/gsl_math.h>
 #include <gsl/gsl_vector.h>
 #include <gsl/gsl_matrix.h>
@@ -178,7 +178,7 @@ typedef struct pspp_linreg_cache_struct pspp_linreg_cache;
  */
 pspp_linreg_cache *pspp_linreg_cache_alloc (size_t n, size_t p);
 
-void pspp_linreg_cache_free (pspp_linreg_cache * c);
+bool pspp_linreg_cache_free (pspp_linreg_cache * c);
 
 /*
   Fit the linear model via least squares. All pointers passed to pspp_linreg