title: GDB corrupted stack frame - How to debug?
body: <p>I have the following stack trace. Is it possible to make out anything useful from this for debugging?</p>
  
  <pre><code>Program received signal SIGSEGV, Segmentation fault.
  0x00000002 in ?? ()
  (gdb) bt
  #0  0x00000002 in ?? ()
  #1  0x00000001 in ?? ()
  #2  0xbffff284 in ?? ()
  Backtrace stopped: previous frame inner to this frame (corrupt stack?)
  (gdb) 
  </code></pre>
  
  <p>Where to start looking at the code when we get a <code>Segmentation fault</code>, and the stack trace is not so useful?</p>
  
  <p>NOTE: If I post the code, then the SO experts will give me the answer. I want to take the guidance from SO and find the answer myself, so I'm not posting the code here. Apologies.</p>