title: How to be sure that mount command is actually finished in qt process
body: <p>I'm developing a program written in qt5, where i need to mount some devices (USB DRIVE) and show in a GUI the contents of that device.
  I'm using QProcess() to mount the device, and after that i explore the folder where the device should be mounted. Unfortunately only few files can be found. </p>
  
  <p>I tryed to add a QThread::sleep() after the mount command, and this is actually work for small devices. So it seems that the correctness of my approach depends on how much i wait for the system to actually mount the device. </p>
  
  <pre><code>pr3.start("mount foo foo");
  pr3.waitForFinished(-1);
  QThread::sleep(6); //This is a patch but it fail depending on the amount of file stored in the device
  </code></pre>
  
  <p>Is there any way to be sure when the QProcess("mount") has finished correctly? 
  I tryed the wawtforfinished(-1) method of QProcess but it doesn't
  seems to work. </p>
  
  <p>Thanks</p>