On Sep 16, 2011, at 11:21 , dct wrote: I disabled the Enable C++ Exceptions setting but I still get the same behavior-- gdb could not unwind ... 30-40% of the time after a Stop/Build and Debug (& an occasional EXC_BAD_ACCESS).
This is not what you said exactly but I think what you're asking is, "What's wrong with gdb and how can I get around it?"
While it's possible you've run across a nasty gdb bug (or a compiler bug that generated invalid debug information, perhaps), you really have no evidence to support that position. I think you have to assume for now that your code (or possible a code library that you use) has a bug that's corrupting the stack. Such a bug could easily produce exactly the symptoms you describe.
The fact that the same code has apparently been working elsewhere before doesn't really provide any proof that no app code bug exists. It may just prove that you've been lucky in the past.
If the stack is being corrupted, there's no reason to believe that the point at which the error is *detected* gives any clue to the place where the error is *caused*. It could be anywhere in the called code, at any nested level. If you treat the called code with greater suspicion, you may find a way of looking in the right place for the problem, rather than (perhaps) looking in the wrong place.
|