[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[warnings 4/7] ONEWAY: Fix declaration-after-statement warning.
From: |
Ben Pfaff |
Subject: |
[warnings 4/7] ONEWAY: Fix declaration-after-statement warning. |
Date: |
Fri, 17 Sep 2010 21:36:29 -0700 |
C90 requires declarations to precede statements within a block.
---
src/language/stats/oneway.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/language/stats/oneway.c b/src/language/stats/oneway.c
index ba7fc5b..aa8a255 100644
--- a/src/language/stats/oneway.c
+++ b/src/language/stats/oneway.c
@@ -360,14 +360,14 @@ updateit (void *user_data,
const union value *valx = case_data (c, varp);
+ struct descriptive_data *dd_total = aux2;
+
+ double weight;
+
if ( var_is_value_missing (varp, valx, exclude))
return;
- struct descriptive_data *dd_total = aux2;
-
- double weight = 1.0;
- if (wv)
- weight = case_data (c, wv)->f;
+ weight = wv != NULL ? case_data (c, wv)->f : 1.0;
moments1_add (dd->mom, valx->f, weight);
if (valx->f * weight < dd->minimum)
--
1.7.1
- Re: [warnings 3/7] Suppress warnings about conversions between char * and unsigned char *., (continued)
- [warnings 4/7] ONEWAY: Fix declaration-after-statement warning.,
Ben Pfaff <=