mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-26 03:30:46 +00:00
Defs: Fix the parser so tokens with 'x' or 'X' as a second character are only treated as hex constants when the first character is '0'. Introduced in r5822.
git-svn-id: https://svn.eduke32.com/eduke32@5907 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
94f615cc52
commit
e24941f0c7
1 changed files with 1 additions and 1 deletions
|
@ -351,7 +351,7 @@ int32_t scriptfile_getsymbolvalue(char const *name, int32_t *val)
|
||||||
{
|
{
|
||||||
if (Bstrlen(name) > 2)
|
if (Bstrlen(name) > 2)
|
||||||
{
|
{
|
||||||
if (tolower(name[1]) == 'x') // hex constants
|
if (name[0] == '0' && tolower(name[1]) == 'x') // hex constants
|
||||||
{
|
{
|
||||||
int64_t x;
|
int64_t x;
|
||||||
sscanf(name + 2, "%" PRIx64 "", &x);
|
sscanf(name + 2, "%" PRIx64 "", &x);
|
||||||
|
|
Loading…
Reference in a new issue