8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-23 10:03:03 +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 6047b68edd
commit 3ea84bf616

View File

@ -2641,7 +2641,7 @@ static SINT64 hex_to_value(const char*& string, const char* end)
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;