Merge "Fix BufferItemConsumer::releaseBuffer error logging" into pi-dev am: 1cfa648d29
am: de5854bac4
Change-Id: I8645bd9d46ae538267913ba8aadfb167e63f44e4
diff --git a/libs/gui/BufferItemConsumer.cpp b/libs/gui/BufferItemConsumer.cpp
index 34e6d80..89bc0c4 100644
--- a/libs/gui/BufferItemConsumer.cpp
+++ b/libs/gui/BufferItemConsumer.cpp
@@ -92,10 +92,13 @@
Mutex::Autolock _l(mMutex);
err = addReleaseFenceLocked(item.mSlot, item.mGraphicBuffer, releaseFence);
+ if (err != OK) {
+ BI_LOGE("Failed to addReleaseFenceLocked");
+ }
err = releaseBufferLocked(item.mSlot, item.mGraphicBuffer, EGL_NO_DISPLAY,
EGL_NO_SYNC_KHR);
- if (err != OK) {
+ if (err != OK && err != IGraphicBufferConsumer::STALE_BUFFER_SLOT) {
BI_LOGE("Failed to release buffer: %s (%d)",
strerror(-err), err);
}