test: Use char instead of unsigned char

This commit is contained in:
MarcoFalke 2019-11-20 13:42:13 -05:00
parent faa8023ce9
commit 2222c30586
No known key found for this signature in database
GPG key ID: CE2B75697E69A548

View file

@ -186,14 +186,15 @@ static void TestHKDF_SHA256_32(const std::string &ikm_hex, const std::string &sa
BOOST_CHECK(HexStr(out, out + 32) == okm_check_hex); BOOST_CHECK(HexStr(out, out + 32) == okm_check_hex);
} }
static std::string LongTestString() { static std::string LongTestString()
{
std::string ret; std::string ret;
for (int i=0; i<200000; i++) { for (int i = 0; i < 200000; i++) {
ret += (unsigned char)(i); ret += (char)(i);
ret += (unsigned char)(i >> 4); ret += (char)(i >> 4);
ret += (unsigned char)(i >> 8); ret += (char)(i >> 8);
ret += (unsigned char)(i >> 12); ret += (char)(i >> 12);
ret += (unsigned char)(i >> 16); ret += (char)(i >> 16);
} }
return ret; return ret;
} }