Open graphitemaster opened 3 years ago
Can we fix this with a simple:
#define ERROR_MESSAGE_SIZE (80 + MAX_VARIABLE_NAME + MAX_VARIABLE_NAME + 15)
The problem is we need to allow for MAX_VARIABLE_NAME to be included TWICE - since that's what we do in some error messages - or else change the error message to not include the function name.
Thoughts?
This is similar to issue #1034 except the method names are not actually longer than 64 characters, they're at 58 characters in length. The body of the method is empty too, and there is no invalid tokens necessary.
It looks like length management is messed up under duplicate names and that alone leads to stack overflow.
Like the other issue, adding more
i
s if it does not crash will make it crash too if it isn't already. This one I think is more interesting from a user perspective because the identifier is less than 64 characters, adding more to exceed it is not surprising either, though it shouldn't crash in this fashion. Without stack protector this leads to a segfault in my case.Output