mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
fixed critical buffer overflow
git-svn-id: https://zerberus.eonerc.rwth-aachen.de:8443/svn/s2ss/trunk@267 8ec27952-4edc-4aab-86aa-e87bb2611832
This commit is contained in:
parent
b7fcd2cc43
commit
6cdcdc0239
1 changed files with 2 additions and 2 deletions
|
@ -43,9 +43,9 @@ void hist_put(struct hist *h, double value)
|
|||
h->lowest = value;
|
||||
|
||||
/* Check bounds and increment */
|
||||
if (value >= h->length)
|
||||
if (idx >= h->length)
|
||||
h->higher++;
|
||||
else if (value < 0)
|
||||
else if (idx < 0)
|
||||
h->lower++;
|
||||
else {
|
||||
h->total++;
|
||||
|
|
Loading…
Add table
Reference in a new issue