[Valgrind-users] Memcheck fails to find error

2013-04-11 Thread Milian Wolff
Hey there, a friend of mine is starting C++ and asked me this apparently simple question: Why does the following program not show me an error? ~~~ #include iostream using namespace std; int main () { int billy[2]; billy[4] = 42; cout billy[4] endl; return 0; } ~~~ My first

Re: [Valgrind-users] Memcheck fails to find error

2013-04-11 Thread Paul Floyd
On 11 Apr 2013, at 21:20, Milian Wolff wrote: Hey there, a friend of mine is starting C++ and asked me this apparently simple question: Why does the following program not show me an error? Hi memcheck is a heap checker, not a stack checker. Try --tool=exp-sgcheck (where sg is stack