From c4646e654a18543be4e2f7d98f63bc4e603128e1 Mon Sep 17 00:00:00 2001 From: Mathias Agopian Date: Sun, 27 Sep 2009 18:44:09 -0700 Subject: [PATCH] Allways dump the list of allocated buffers when an allocation fails. Hopefully this will help us understand cases of failures such as [2148405] --- libs/surfaceflinger/BufferAllocator.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libs/surfaceflinger/BufferAllocator.cpp b/libs/surfaceflinger/BufferAllocator.cpp index 19867a519a791..caf9bec767fd1 100644 --- a/libs/surfaceflinger/BufferAllocator.cpp +++ b/libs/surfaceflinger/BufferAllocator.cpp @@ -102,6 +102,10 @@ status_t BufferAllocator::alloc(uint32_t w, uint32_t h, PixelFormat format, rec.vaddr = 0; rec.size = h * stride[0] * bytesPerPixel(format); list.add(*handle, rec); + } else { + String8 s; + dump(s); + LOGD("%s", s.string()); } return err;