[PATCH 2/5] planner.c: use implicit struct initializer
Lubomir I. Ivanov
neolit123 at gmail.com
Mon Jun 9 14:05:57 PDT 2014
From: "Lubomir I. Ivanov" <neolit123 at gmail.com>
We should either use mplicit struct initializers (empty braces { }
or double braced zero {{ 0 }}) or memset the struct.
Signed-off-by: Lubomir I. Ivanov <neolit123 at gmail.com>
---
planner.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/planner.c b/planner.c
index b4400a8..8cc9b6f 100644
--- a/planner.c
+++ b/planner.c
@@ -369,7 +369,7 @@ struct divedatapoint *get_nth_dp(struct diveplan *diveplan, int idx)
{
struct divedatapoint **ldpp, *dp = diveplan->dp;
int i = 0;
- struct gasmix air = { 0 };
+ struct gasmix air = { };
ldpp = &diveplan->dp;
while (dp && i++ < idx) {
--
1.7.11.msysgit.0
More information about the subsurface
mailing list