title: CreateProcess can start a process, but QProcess cannot... why?
body: <p>I am writing a windows QT app that needs to launch other apps. If I use the following windows calls everything works fine:</p>
  
  <pre><code>QString qsExePath = "C:\\Program Files (x86)\\Some Company\\SomeApp.exe";
  QString qsCommandLine = "";
  
  
  DWORD dwLastError = 0;
  STARTUPINFO startupInfo;
  ZeroMemory(&amp;startupInfo, sizeof(startupInfo));
  startupInfo.cb = sizeof(startupInfo);
  startupInfo.dwFlags = STARTF_USESHOWWINDOW;
  startupInfo.wShowWindow = (WORD)1;
  
  PROCESS_INFORMATION processInfo;
  ZeroMemory(&amp;processInfo, sizeof(processInfo));
  
  if (CreateProcess((TCHAR*)(qsExePath.utf16()), (TCHAR*)(qsCommandLine.utf16()), 
      NULL, NULL, FALSE, 0, NULL, NULL, 
      &amp;startupInfo, &amp;processInfo))
  {
      CloseHandle(processInfo.hProcess);
      CloseHandle(processInfo.hThread);
  }
  else
  {
      dwLastError = GetLastError();
  }
  </code></pre>
  
  <p>However, if I use the following QT calls it does not work and fails with QProcess::Unknown Error. </p>
  
  <pre><code>QProcess process;
  bool bStarted = process.startDetached(qsExePath);
  qDebug()  &lt;&lt; process.error();   
  </code></pre>
  
  <p>I can get QProcess to work if copy SomeApp.exe to my %TMP% directory and change the qsExePath accordingly, so it is obviously some kind of permissions error. I don't understand why though... if it were really permissions, shouldn't my CreateProcess windows call fail?</p>