mirror of
https://github.com/subsurface/subsurface.git
synced 2024-12-01 06:30:26 +00:00
Fix unitialized variable use
I ran subsurface with valgrind and it found a few errors. [Dirk Hohndel: split this out from a much bigger patch that is still under review] Signed-off-by: Patrick Valsecchi <patrick@thus.ch> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
34a747dead
commit
ab7d96c96f
1 changed files with 2 additions and 0 deletions
|
@ -1372,6 +1372,7 @@ void compare_samples(struct plot_data *e1, struct plot_data *e2, char *buf, int
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
count = 0;
|
count = 0;
|
||||||
|
avg_speed = 0;
|
||||||
max_speed = 0;
|
max_speed = 0;
|
||||||
min_speed = INT_MAX;
|
min_speed = INT_MAX;
|
||||||
|
|
||||||
|
@ -1385,6 +1386,7 @@ void compare_samples(struct plot_data *e1, struct plot_data *e2, char *buf, int
|
||||||
last_sec = start->sec;
|
last_sec = start->sec;
|
||||||
last_pressure = GET_PRESSURE(start);
|
last_pressure = GET_PRESSURE(start);
|
||||||
|
|
||||||
|
data = start;
|
||||||
while (data != stop) {
|
while (data != stop) {
|
||||||
data = start+count;
|
data = start+count;
|
||||||
if (sum)
|
if (sum)
|
||||||
|
|
Loading…
Reference in a new issue