From b45acf115d3485ee5f366af0597eb885400cf613 Mon Sep 17 00:00:00 2001 From: Ricard Borrell <75077385+rickb80@users.noreply.github.com> Date: Sun, 20 Aug 2023 19:29:15 +0000 Subject: [PATCH] Set zeros in last positions when 8 values are added in assocaitiveCache --- src/hashdb/database_associative_cache.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/hashdb/database_associative_cache.cpp b/src/hashdb/database_associative_cache.cpp index 933e0af0b..e257d79ac 100644 --- a/src/hashdb/database_associative_cache.cpp +++ b/src/hashdb/database_associative_cache.cpp @@ -209,6 +209,11 @@ void DatabaseMTAssociativeCache::addKeyValue(Goldilocks::Element (&key)[4], cons values[cacheIndexValue + 9] = value[9]; values[cacheIndexValue + 10] = value[10]; values[cacheIndexValue + 11] = value[11]; + }else{ + values[cacheIndexValue + 8] = Goldilocks::zero(); + values[cacheIndexValue + 9] = Goldilocks::zero(); + values[cacheIndexValue + 10] = Goldilocks::zero(); + values[cacheIndexValue + 11] = Goldilocks::zero(); } // // Forced index insertion