WMF: Fixed shutdown sequence.

A wrong shutdown sequence was causing a wait condition to never be met,
resulting in a 5 seconds hang on shutdown.
Also reduced the wait condition timeout to 100 ms.

Task-number: QTBUG-28432

Change-Id: Ib415bf66634603d839be3e34e497e3a3c5a19ad9
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
Reviewed-by: Jason Barron <jason@cutehacks.com>
This commit is contained in:
Yoann Lopes
2012-12-06 15:42:47 +01:00
committed by The Qt Project
parent 31fdbb1c22
commit ad83534736
3 changed files with 4 additions and 3 deletions

View File

@@ -454,7 +454,7 @@ void MFPlayerSession::close()
if (m_session) {
hr = m_session->Close();
if (SUCCEEDED(hr)) {
DWORD dwWaitResult = WaitForSingleObject(m_hCloseEvent, 5000);
DWORD dwWaitResult = WaitForSingleObject(m_hCloseEvent, 100);
if (dwWaitResult == WAIT_TIMEOUT) {
qWarning() << "session close time out!";
}