OSDN Git Service

Don't flatten nullptrs
authorJohn Reck <jreck@google.com>
Thu, 28 Apr 2016 17:12:47 +0000 (10:12 -0700)
committerJohn Reck <jreck@google.com>
Thu, 28 Apr 2016 17:12:47 +0000 (10:12 -0700)
commitce8e5df3c11616f3eb7867ce89558b530651166c
treebbbe0ef2e519bc4cab38c28135d738eef40a7faf
parent44e9c027958ef5d7f8c8a06137ff9832b43114fb
Don't flatten nullptrs

Bug: 28428970

BufferQueueProducer can return a nullptr for
the GraphicBuffer if there's nothing queued, which
IGraphicBufferProducer would attempt to flatten.

It's useful to distinguish that there's nothing queued
instead of just generic error, so fix IGraphicBufferProducer
to handle null GraphicBuffers.

Change-Id: I9e2b11e107e093d209a89a01d14feec3e885f268
libs/gui/IGraphicBufferProducer.cpp