I just ran out of work on the stack, it was a database, and there were threads on it, basically the previous developer threw a large array onto the stack, and in any case, the stack was low. The software was compiled using Microsoft Visual Studio 2015.
Despite the fact that the stack ended in the stream, it was silent and continued, but the stack only overflowed when access to the data contents on the stack came.
The best advice I can give is not to declare arrays on the stack, especially in complex applications and especially in threads, use heap instead. What is this for;)
Also keep in mind that this may not work right after the stack is declared, but only with access. I assume that the compiler declares the stack to be βoptimisticβ, i.e. Suppose the stack is declared and is large enough until it starts using it, and then finds out that the stack does not exist.
Different operating systems may have different stack declaration policies. Please leave a comment if you know what this policy is.
Owl Aug 18 '17 at 18:13 2017-08-18 18:13
source share