Merge pull request #6359

f9441c5 Fixed string_ref usage bug in epee::from_hex::vector (vtnerd)
This commit is contained in:
luigi1111 2020-04-21 08:38:21 -05:00
commit 06c81b6527
No known key found for this signature in database
GPG key ID: F4ACA0183641E010
2 changed files with 6 additions and 3 deletions

View file

@ -841,6 +841,9 @@ TEST(HexLocale, String)
// decoding it this way also, ignoring spaces and colons between the numbers
hex.assign("00:ff 0f:f0");
EXPECT_EQ(source, epee::from_hex_locale::to_vector(hex));
hex.append("f0");
EXPECT_EQ(source, epee::from_hex_locale::to_vector(boost::string_ref{hex.data(), hex.size() - 2}));
}
TEST(ToHex, Array)