1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/node/ synced 2025-03-09 00:00:00 +01:00

window: fix buffer overflow

This commit is contained in:
Steffen Vogel 2019-03-09 00:30:58 +01:00
parent 3c7b9259a8
commit e7c5ee770c

View file

@ -55,7 +55,7 @@ double window_update(struct window *w, double in)
{
double out = w->data[(w->pos - w->steps) & w->mask];
w->data[w->pos++] = in;
w->data[w->pos++ & w->mask] = in;
return out;
}