Skip to content
Permalink
Browse files

- fixed crash on parsing bad hex number

  • Loading branch information...
alexey-lysiuk committed Aug 25, 2019
1 parent 574e079 commit cc1f18a3286b2c11bb475a8a44277d308f8c6bcc
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/utility/sc_man.cpp
@@ -1283,7 +1283,8 @@ int ParseHex(const char* hex, FScriptPosition* sc)
else if (*str >= 'A' && *str <= 'F')
num += 10 + *str - 'A';
else {
sc->Message(MSG_WARNING, "Bad hex number: %s", hex);
if (sc) sc->Message(MSG_WARNING, "Bad hex number: %s", hex);
else Printf("Bad hex number: %s\n", hex);
return 0;
}
str++;

0 comments on commit cc1f18a

Please sign in to comment.
You can’t perform that action at this time.