mirror of
https://codeberg.org/anoncontributorxmr/monero.git
synced 2024-11-27 05:13:25 +01:00
Merge pull request #6675
3721d56
epee: fix array underflow in unicode parsing (moneromooo-monero)
This commit is contained in:
commit
803f58553b
@ -196,7 +196,7 @@ namespace misc_utils
|
|||||||
uint32_t dst = 0;
|
uint32_t dst = 0;
|
||||||
for (int i = 0; i < 4; ++i)
|
for (int i = 0; i < 4; ++i)
|
||||||
{
|
{
|
||||||
const unsigned char tmp = isx[(int)*++it];
|
const unsigned char tmp = isx[(unsigned char)*++it];
|
||||||
CHECK_AND_ASSERT_THROW_MES(tmp != 0xff, "Bad Unicode encoding");
|
CHECK_AND_ASSERT_THROW_MES(tmp != 0xff, "Bad Unicode encoding");
|
||||||
dst = dst << 4 | tmp;
|
dst = dst << 4 | tmp;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user