diff options
author | Arisotura <thetotalworm@gmail.com> | 2020-02-15 17:26:48 +0100 |
---|---|---|
committer | Arisotura <thetotalworm@gmail.com> | 2020-02-15 17:26:48 +0100 |
commit | 3a4947fbbe8a346b4e8a6d99ecbc4507f55dd39e (patch) | |
tree | f43481de6c5517a6ae6c31a203800c2a5ba6a7f6 /src | |
parent | e40d414c567c46fd971b2b09d669a2eae7ce674a (diff) |
also that might have been bad for security. who knows.
Diffstat (limited to 'src')
-rw-r--r-- | src/AREngine.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/AREngine.cpp b/src/AREngine.cpp index 760ca39..ab3969a 100644 --- a/src/AREngine.cpp +++ b/src/AREngine.cpp @@ -95,6 +95,12 @@ void ParseTextCode(char* text, u32* code, int len) // or whatever this should be if (nout & 1) { printf("AR: code was missing one word??\n"); + if (nout >= len) + { + // OH SHIT SHIT SHIT SHIT + printf("AR: code too long!\n"); + return; + } *code++ = 0; } } |