mirror of
https://git.wownero.com/wownero/wownero.git
synced 2024-08-15 01:03:23 +00:00
multiexp: fix maxscalar off by one
Reported by QuarksLab.
This commit is contained in:
parent
7ed496cc78
commit
a129bbd944
1 changed files with 1 additions and 1 deletions
|
@ -605,7 +605,7 @@ rct::key pippenger(const std::vector<MultiexpData> &data, const std::shared_ptr<
|
||||||
maxscalar = data[i].scalar;
|
maxscalar = data[i].scalar;
|
||||||
}
|
}
|
||||||
size_t groups = 0;
|
size_t groups = 0;
|
||||||
while (groups < 256 && pow2(groups) < maxscalar)
|
while (groups < 256 && !(maxscalar < pow2(groups)))
|
||||||
++groups;
|
++groups;
|
||||||
groups = (groups + c - 1) / c;
|
groups = (groups + c - 1) / c;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue