Skip to content
Snippets Groups Projects
Commit 49d63ad0 authored by Marek Vavruša's avatar Marek Vavruša
Browse files

trie: missing type conversion before abs()

parent 2b3c828a
No related branches found
No related tags found
2 merge requests!330Knsupdate pubkey processing fix,!322Hattrie missing conversion
......@@ -500,7 +500,7 @@ int hattrie_split_mid(node_ptr node, unsigned *left_m, unsigned *right_m)
while (j + 1 < node.b->c1) {
d = abs((int) (*left_m + cs[j + 1]) - (int) (*right_m - cs[j + 1]));
if (d <= abs(*left_m - *right_m) && *left_m + cs[j + 1] < all_m) {
if (d <= abs((int) (*left_m) - (int) (*right_m)) && *left_m + cs[j + 1] < all_m) {
j += 1;
*left_m += cs[j];
*right_m -= cs[j];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment