Merge "crash if getNativeBuffer() called on NULL GraphicBuffer" into lmp-dev
This commit is contained in:
commit
45e695a248
@ -126,6 +126,7 @@ void GraphicBuffer::dumpAllocationsToSystemLog()
|
|||||||
|
|
||||||
ANativeWindowBuffer* GraphicBuffer::getNativeBuffer() const
|
ANativeWindowBuffer* GraphicBuffer::getNativeBuffer() const
|
||||||
{
|
{
|
||||||
|
LOG_ALWAYS_FATAL_IF(this == NULL, "getNativeBuffer() called on NULL GraphicBuffer");
|
||||||
return static_cast<ANativeWindowBuffer*>(
|
return static_cast<ANativeWindowBuffer*>(
|
||||||
const_cast<GraphicBuffer*>(this));
|
const_cast<GraphicBuffer*>(this));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user