8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-22 23:23:02 +01:00

Fixed random conversion errors (FBT test "functional.gtcs.cast-datatypes" failed sometimes).

This commit is contained in:
hvlad 2020-06-13 14:19:38 +03:00
parent bb60e14c32
commit e7ac0c0a9b

View File

@ -3536,7 +3536,7 @@ static void hex_to_value(const char*& string, const char* end, RetPtr* retValue)
int nibble = ((end - string) & 1);
char ch;
while ((DIGIT((ch = UPPER(*string)))) || ((ch >= 'A') && (ch <= 'F')))
while ((string < end) && ((DIGIT((ch = UPPER(*string)))) || ((ch >= 'A') && (ch <= 'F'))))
{
// Now convert the character to a nibble
SSHORT c;