aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2014-05-15 01:21:22 -0700
committerChris Robinson <[email protected]>2014-05-15 01:21:22 -0700
commit6dcd4fec7d0c520742c424eb04b286d8db2b4df9 (patch)
treed953a18f930ccfe13df8f012e8ca43f21803bfac
parentef1b34dcd28a47d1917e78dce7870a4d4871678e (diff)
Remove some unnecessary casts
-rw-r--r--utils/makehrtf.c25
1 files changed, 13 insertions, 12 deletions
diff --git a/utils/makehrtf.c b/utils/makehrtf.c
index f98f6820..f8ac66c6 100644
--- a/utils/makehrtf.c
+++ b/utils/makehrtf.c
@@ -769,21 +769,22 @@ static int HpTpdfDither (const double in, int * hpHist) {
}
// Allocates an array of doubles.
-static double * CreateArray (const size_t n) {
- double * a = NULL;
-
- a = (double *) calloc (n, sizeof (double));
- if (a == NULL) {
- fprintf (stderr, "Error: Out of memory.\n");
- exit (-1);
- }
- return (a);
+static double *CreateArray(const size_t n)
+{
+ double *a;
+
+ a = calloc(n, sizeof(double));
+ if(a == NULL)
+ {
+ fprintf(stderr, "Error: Out of memory.\n");
+ exit(-1);
+ }
+ return a;
}
// Frees an array of doubles.
-static void DestroyArray (const double * a) {
- free ((void *) a);
-}
+static void DestroyArray(double *a)
+{ free(a); }
// Complex number routines. All outputs must be non-NULL.