diff options
author | bunnei <bunneidev@gmail.com> | 2018-02-09 22:17:31 -0500 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2018-02-09 23:33:49 -0500 |
commit | 725304094eec2985f7e3b48efa0055171b1e7397 (patch) | |
tree | 69d70ae82daf9821da0c58274176225c6d169e91 | |
parent | 63de56ee0ff50895f1c318949c027cc96ee40b9c (diff) |
nvflinger: (Hack) Use first available buffer if none are found.
-rw-r--r-- | src/core/hle/service/nvflinger/buffer_queue.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/core/hle/service/nvflinger/buffer_queue.cpp b/src/core/hle/service/nvflinger/buffer_queue.cpp index c7206a683..f90c7ca51 100644 --- a/src/core/hle/service/nvflinger/buffer_queue.cpp +++ b/src/core/hle/service/nvflinger/buffer_queue.cpp @@ -40,7 +40,11 @@ u32 BufferQueue::DequeueBuffer(u32 pixel_format, u32 width, u32 height) { return igbp_buffer.format == pixel_format && igbp_buffer.width == width && igbp_buffer.height == height; }); - ASSERT(itr != queue.end()); + if (itr == queue.end()) { + LOG_CRITICAL(Service_NVDRV, "no free buffers for pixel_format=%d, width=%d, height=%d", + pixel_format, width, height); + itr = queue.begin(); + } itr->status = Buffer::Status::Dequeued; return itr->slot; |