diff options
-rw-r--r-- | chromium/gpu/command_buffer/client/implementation_base.cc | 8 | ||||
-rw-r--r-- | chromium/gpu/command_buffer/client/implementation_base.h | 2 |
2 files changed, 6 insertions, 4 deletions
diff --git a/chromium/gpu/command_buffer/client/implementation_base.cc b/chromium/gpu/command_buffer/client/implementation_base.cc index 0492f62a9f7..8a3aa39c7fc 100644 --- a/chromium/gpu/command_buffer/client/implementation_base.cc +++ b/chromium/gpu/command_buffer/client/implementation_base.cc @@ -256,9 +256,9 @@ gpu::ContextResult ImplementationBase::Initialize( return gpu::ContextResult::kSuccess; } -void ImplementationBase::WaitForCmd() { +bool ImplementationBase::WaitForCmd() { TRACE_EVENT0("gpu", "ImplementationBase::WaitForCmd"); - helper_->Finish(); + return helper_->Finish(); } int32_t ImplementationBase::GetResultShmId() { @@ -301,7 +301,9 @@ bool ImplementationBase::GetBucketContents(uint32_t bucket_id, } helper_->GetBucketData(bucket_id, offset, buffer.size(), buffer.shm_id(), buffer.offset()); - WaitForCmd(); + if (!WaitForCmd()) { + return false; + } } uint32_t size_to_copy = std::min(size, buffer.size()); memcpy(&(*data)[offset], buffer.address(), size_to_copy); diff --git a/chromium/gpu/command_buffer/client/implementation_base.h b/chromium/gpu/command_buffer/client/implementation_base.h index 9e1ec175552..25b19800fbd 100644 --- a/chromium/gpu/command_buffer/client/implementation_base.h +++ b/chromium/gpu/command_buffer/client/implementation_base.h @@ -107,7 +107,7 @@ class GLES2_IMPL_EXPORT ImplementationBase gpu::ContextResult Initialize(const SharedMemoryLimits& limits); // Waits for all commands to execute. - void WaitForCmd(); + bool WaitForCmd(); // Gets the value of the result. template <typename T> |