summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Pablo Ceballos <pceballos@google.com> 2016-03-21 16:54:08 -0700
committer Pablo Ceballos <pceballos@google.com> 2016-03-21 16:54:08 -0700
commit6366a10fd8223c91f1a3422620800cd6ac67ef90 (patch)
tree0a8820db2deb9771f74cd1a17a274dc76905e7b0
parentb49576d5241859a3cf03c9f34b8030ad25d3806b (diff)
Add debug dump if about to segfault
Bug 27674961 Change-Id: I82242d2c1b7cc9646d233bab896f718652e9ce2c
-rw-r--r--libs/gui/GLConsumer.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/libs/gui/GLConsumer.cpp b/libs/gui/GLConsumer.cpp
index 149f5bd65c..29d52684c8 100644
--- a/libs/gui/GLConsumer.cpp
+++ b/libs/gui/GLConsumer.cpp
@@ -393,6 +393,21 @@ status_t GLConsumer::updateAndReleaseLocked(const BufferItem& item,
return err;
}
+ // For investigating b/27674961
+ if (mEglSlots[slot].mEglImage == nullptr) {
+ ALOGE("If you see this message in a log please post the log to "
+ "b/27674961");
+ ALOGE("slot = %d, mCurrentTexture = %d, mCurrentTextureImage = %p",
+ slot, mCurrentTexture, mCurrentTextureImage.get());
+ for (int i = 0; i < BufferQueue::NUM_BUFFER_SLOTS; i++) {
+ ALOGE("mEglSlots[%d].mEglImage = %p", i,
+ mEglSlots[i].mEglImage.get());
+ }
+ String8 dump;
+ dumpLocked(dump, "");
+ ALOGE("%s", dump.string());
+ }
+
// Ensure we have a valid EglImageKHR for the slot, creating an EglImage
// if nessessary, for the gralloc buffer currently in the slot in
// ConsumerBase.