Commit 3be43be0 by Jamie Madill Committed by Commit Bot

Fix crash in IndexDataManagerPerfTest.

Using a mock BufferFactory would sometimes leave us with a nullptr in the VertexBufferInterface class. This would lead to a null deref in the perf tests only. Fix this by adding a null check. BUG=593541 Change-Id: I98685a9990124f521cd26ed81a26aeb11aafaf0d Reviewed-on: https://chromium-review.googlesource.com/331768Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
parent 4e25a0d6
......@@ -63,7 +63,10 @@ VertexBufferInterface::VertexBufferInterface(BufferFactoryD3D *factory, bool dyn
VertexBufferInterface::~VertexBufferInterface()
{
mVertexBuffer->release();
if (mVertexBuffer)
{
mVertexBuffer->release();
}
}
unsigned int VertexBufferInterface::getSerial() const
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment