Open
Description
Describe the bug
The char array defined here should be created from a non const variable or a define.
IIRC this is not valid C/C++ code and the behavior is undefined. It is very likely that other data is overwritten. I am wondering that this code compiles at all.
How To Reproduce
Call intToString.
Software (please complete the following information if applicable)
- IDE and Version: all
- OS: all
Possible solutions
Use a string as buffer and resize to the required length because the function returns a string anyway.