Strange bug in Release mode
I am using VS2012. I have a bug in my code that i don't know how to overcome as it appears in bizarre situation. It works fine in Debug but crashes in Release mode.
I have a class with couple of vectors and some pointers:
... more data
When i introduced one more vector (vBar4) to this class it crashes my app even if don't use it anywhere
, if i comment it then everything works.
WTF is going on?
Thank you for your time.
Undefined behavior is going on. In particular memory corruption can cause strange problems in unrelated parts of code.
Any tips how to debug it in Release mode?
You may want to investigate how and where you actually allocate memory for your pointer.
|Any tips how to debug it in Release mode? |
You just need to enable debug symbols. In most cases, debugging will still be possible, even with optimizations enabled.
"Clean" then "Rebuild" and now it works.
Topic archived. No new replies allowed.