fix leak of Light object (in this private instance, the caller is transferring
ownership of the object, so the receive does not need to call ref). Review URL: https://codereview.appspot.com/6348045 git-svn-id: http://skia.googlecode.com/svn/trunk@4360 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
parent
0456e0b7b8
commit
51f3866995
@ -430,7 +430,8 @@ SkLightingImageFilter::SkLightingImageFilter(SkLight* light, const SkColor& ligh
|
|||||||
fSurfaceScale(SkScalarDiv(surfaceScale, SkIntToScalar(255)))
|
fSurfaceScale(SkScalarDiv(surfaceScale, SkIntToScalar(255)))
|
||||||
{
|
{
|
||||||
SkASSERT(fLight);
|
SkASSERT(fLight);
|
||||||
fLight->ref();
|
// our caller knows that we take ownership of the light, so we don't
|
||||||
|
// need to call ref() here.
|
||||||
}
|
}
|
||||||
|
|
||||||
SkImageFilter* SkLightingImageFilter::CreateDistantLitDiffuse(
|
SkImageFilter* SkLightingImageFilter::CreateDistantLitDiffuse(
|
||||||
|
Loading…
Reference in New Issue
Block a user