Bug 1566285 - VRManager::PullState will no longer block when no wait condition is passed and enumeration has not yet completed. r=daoshengmu

Differential Revision: https://phabricator.services.mozilla.com/D38137

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Kearwood "Kip" Gilbert 2019-07-16 00:54:30 +00:00
Родитель 088309ee7c
Коммит d016bb0e3a
1 изменённых файлов: 5 добавлений и 1 удалений

Просмотреть файл

@ -1002,7 +1002,11 @@ void VRManager::PullState(
if (!aWaitCondition || aWaitCondition()) {
return;
}
} // if (isCleanCopy)
} else if (!aWaitCondition) {
// We did not get a clean copy, and we are not waiting for a condition
// to exit from PullState call.
return;
}
// Yield the thread while polling
YieldThread();
# if defined(XP_WIN)