X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Flanguage%2Fstats%2Ffrequencies.q;h=39882e76c527c8d46e51bb708bcb3f7c5bfb6af2;hb=a4ae68f966bc574326d429119878e733069ced14;hp=db480bce497ff8fc574bf6140c19a1b22f713a7f;hpb=de881ed979f2a6c382589b9d54d485ad88323821;p=pspp-builds.git diff --git a/src/language/stats/frequencies.q b/src/language/stats/frequencies.q index db480bce..39882e76 100644 --- a/src/language/stats/frequencies.q +++ b/src/language/stats/frequencies.q @@ -36,6 +36,7 @@ #include #include #include +#include #include #include #include @@ -267,8 +268,8 @@ static void determine_charts (void); static void calc_stats (struct variable *v, double d[frq_n_stats]); -static void precalc (void *); -static bool calc (struct ccase *, void *); +static void precalc (const struct ccase *, void *); +static bool calc (const struct ccase *, void *); static void postcalc (void *); static void postprocess_freq_tab (struct variable *); @@ -494,7 +495,7 @@ determine_charts (void) /* Add data from case C to the frequency table. */ static bool -calc (struct ccase *c, void *aux UNUSED) +calc (const struct ccase *c, void *aux UNUSED) { double weight; size_t i; @@ -549,10 +550,12 @@ calc (struct ccase *c, void *aux UNUSED) /* Prepares each variable that is the target of FREQUENCIES by setting up its hash table. */ static void -precalc (void *aux UNUSED) +precalc (const struct ccase *first, void *aux UNUSED) { size_t i; + output_split_file_values (first); + pool_destroy (gen_pool); gen_pool = pool_create ();