title: Release bugs only show up when running EXE outside of Visual Studio
body: <p>I have an issue that I am trying to debug that only happens when I run the release exe built directly outside of Visual Studio. When I am executing it from within Visual Studio the program behaves normally, even when using specific project properties to debug a "release" build, such as turning on optimizations, explained on the following page.</p>
  
  <p><a href="http://msdn.microsoft.com/en-us/library/fsk896zz%28v=vs.100%29.aspx" rel="nofollow noreferrer">http://msdn.microsoft.com/en-us/library/fsk896zz%28v=vs.100%29.aspx</a></p>
  
  <p>I experience no issues using those settings and running/debugging from withing VS, but when I copy the exe and required files (images and some dll) to it's own directory and run the exe directly instead of through VS2010 I experience a couple errors. This is making it hard to debug as I can't get the issue to occur inside VS no matter what settings I use.</p>
  
  <p>Am I missing some settings or is there still more things that happen differently outside of VS2010 that I can't simulate from within VS 2010?</p>
  
  <p>I am not using any arguments or environment variables that could be affecting it and the file structure from the working directory is identical to the way it is in the source code directory.</p>
  
  <p>Edit:
  Found the bug (uninitialized variable) by attaching to the exe using the information here:
  <a href="https://stackoverflow.com/questions/11146301/release-build-changes-behavior-when-run-outside-of-the-debugger">Release build changes behavior when run outside of the debugger</a></p>