-
-
Notifications
You must be signed in to change notification settings - Fork 222
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
629b9ea
commit 6a0135c
Showing
4 changed files
with
34 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -218,6 +218,13 @@ UCHAR CVT_get_numeric(const UCHAR* string, const USHORT length, SSHORT* scale, v | |
bool digit_seen = false, fraction = false, over = false; | ||
|
||
const UCHAR* p = string; | ||
if (p[0] == '0' && p[1] == 'X') | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
AlexPeshkoff
via email
Author
Member
|
||
{ | ||
*(Int128*) ptr = CVT_hex_to_int128(reinterpret_cast<const char*>(p + 2), length - 2); | ||
This comment has been minimized.
Sorry, something went wrong. |
||
*scale = 0; | ||
return dtype_int128; | ||
} | ||
|
||
const UCHAR* const end = p + length; | ||
for (; p < end; p++) | ||
{ | ||
|
I see that this function is not called with null-terminated string, but maybe it's always have length >= 2?
Should not the length be checked here to avoid read garbage at
p[1]
?