Program disappear in Release mode but work fine with Beep(0,0) inserted
<p>The program works fine under a Debugger (even in release mode) so I have to insert Beep(500,200) to find out the last spot that it fails. I narrow it down to a thread proc that call CreateProcess(). If the Beep is inserted after the call the program would vanish without sound, but if the Beep is inserted before: it beeps and continues without error.</p>

<p>To prevent the annoying beep, I replace it with Beep(0,0) and has been happy. I did try with Sleep(0) but that does not work.</p>

<p>I used to work as a Lisp programmer and has some similar experiences: inserting (princ "debug") until I locate the spot then replacing it with (princ)</p>

<p>The question is why?</p>
