title: nonblocking thread with proper handling of child processess on windows
body: <p>i have the main thread try to <code>CreateProcess()</code> but the main thread need to be non-blocking i am kind of lost on how to do this on windows on linux i am kinda know my way around but on windows</p>
  
  <pre><code>int main () {
      while (1) {
  
       // do some stuff 
       CreateProcess();    
  
       // i want a way to handle these processes exit codes and away of signaling when 
       the process has returned, i am thinking of using
       WaitForSingleObject() with 0 timeout but i dont know how to go about it 
       any help will be appreciated, thank you.
  
  
      }
  
  
  }
  </code></pre>