Bug 1373815: Remove checking for device reset (twice). r?dvander
MozReview-Commit-ID: 8ak07Wt77J6
--- a/gfx/layers/d3d11/HelpersD3D11.h
+++ b/gfx/layers/d3d11/HelpersD3D11.h
@@ -12,19 +12,17 @@
namespace mozilla {
namespace layers {
template <typename T> static inline bool
WaitForGPUQuery(ID3D11Device* aDevice, ID3D11DeviceContext* aContext, ID3D11Query* aQuery, T* aOut)
{
TimeStamp start = TimeStamp::Now();
while (aContext->GetData(aQuery, aOut, sizeof(*aOut), 0) != S_OK) {
- if (aDevice->GetDeviceRemovedReason() != S_OK) {
- return false;
- }
+ MOZ_ASSERT(aDevice->GetDeviceRemovedReason() == S_OK);
if (TimeStamp::Now() - start > TimeDuration::FromSeconds(2)) {
return false;
}
Sleep(0);
}
return true;
}