title: Random Segmentation Fault
body: <p>I am working on a game. At some places, sometimes I receive a segmentation fault and at all other times the code works properly. If I run the game again (after receiving segmentation fault) it recovers back (without any code changes) and runs fine. But after some time again this happens.</p>
  
  <p>I tried debugging it using GDB. I got the following information:</p>
  
  <ol>
  <li>there is a function call : func(&amp;s.x), where s is a structure and x is its member of type int. The address (&amp;s.x) is 0xb3456721</li>
  <li>In function func the value received in the argument is 0xb.</li>
  <li>The program crashes saying memory at 0xb cannot be accessed. When I print the variable using GDB, I again receive memory cannot be accessed.</li>
  </ol>
  
  <p>Any ideas Why this would happen?</p>