Protect against unref/ref of stencil buffer.
Over the shoulder review from robertphillips@google.com git-svn-id: http://skia.googlecode.com/svn/trunk@6476 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
parent
56f233ab54
commit
8e2999fd24
@ -95,6 +95,10 @@ void GrRenderTarget::overrideResolveRect(const GrIRect rect) {
|
||||
}
|
||||
|
||||
void GrRenderTarget::setStencilBuffer(GrStencilBuffer* stencilBuffer) {
|
||||
if (stencilBuffer == fStencilBuffer) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (NULL != fStencilBuffer) {
|
||||
fStencilBuffer->unref();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user