Unverified Commit 0ebd2c82 authored by kladko's avatar kladko

SKALE-3481-NIGHTLY

parent 24d705dd
...@@ -67,10 +67,9 @@ string ConvertToString(T field_elem, int base = 10) { ...@@ -67,10 +67,9 @@ string ConvertToString(T field_elem, int base = 10) {
SAFE_CHAR_BUF(arr, mpz_sizeinbase(t, base) + 2); SAFE_CHAR_BUF(arr, mpz_sizeinbase(t, base) + 2);
mpz_get_str(arr, base, t); mpz_get_str(arr, base, t);
mpz_clear(t);
mpz_clear(t);
string output = arr; string output = arr;
return output; return output;
} }
...@@ -82,8 +81,7 @@ string convertHexToDec(const string &hex_str) { ...@@ -82,8 +81,7 @@ string convertHexToDec(const string &hex_str) {
try { try {
if (mpz_set_str(dec, hex_str.c_str(), 16) == -1) { if (mpz_set_str(dec, hex_str.c_str(), 16) == -1) {
mpz_clear(dec); goto clean;
return ret;
} }
SAFE_CHAR_BUF(arr, mpz_sizeinbase(dec, 10) + 2); SAFE_CHAR_BUF(arr, mpz_sizeinbase(dec, 10) + 2);
...@@ -97,6 +95,10 @@ string convertHexToDec(const string &hex_str) { ...@@ -97,6 +95,10 @@ string convertHexToDec(const string &hex_str) {
throw SGXException(UNKNOWN_ERROR, ""); throw SGXException(UNKNOWN_ERROR, "");
} }
clean:
mpz_clear(dec);
return ret; return ret;
} }
......
...@@ -247,7 +247,7 @@ void TestUtils::sendRPCRequest() { ...@@ -247,7 +247,7 @@ void TestUtils::sendRPCRequest() {
Json::Value blsPublicKeys; Json::Value blsPublicKeys;
for (int i6 = 0; i6 < 10000; i6++) { for (int i6 = 0; i6 < 2; i6++) {
Json::Value blsPublicKeys = c.calculateAllBLSPublicKeys(publicShares, t, n); Json::Value blsPublicKeys = c.calculateAllBLSPublicKeys(publicShares, t, n);
CHECK_STATE(blsPublicKeys["status"] == 0); CHECK_STATE(blsPublicKeys["status"] == 0);
} }
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<ProdID>0</ProdID> <ProdID>0</ProdID>
<ISVSVN>1</ISVSVN> <ISVSVN>1</ISVSVN>
<StackMaxSize>0x100000</StackMaxSize> <StackMaxSize>0x100000</StackMaxSize>
<HeapMaxSize>0x100000</HeapMaxSize> <HeapMaxSize>0x200000</HeapMaxSize>
<TCSNum>16</TCSNum> <TCSNum>16</TCSNum>
<TCSMaxNum>16</TCSMaxNum> <TCSMaxNum>16</TCSMaxNum>
<TCSMinPool>16</TCSMinPool> <TCSMinPool>16</TCSMinPool>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment