aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/effects
diff options
context:
space:
mode:
authorGravatar sugoi <sugoi@chromium.org>2014-10-09 08:09:04 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2014-10-09 08:09:04 -0700
commit9a7f29ee5e40071d3b3025d22bbfa58953e6c821 (patch)
treea0ba3f50e98c0e87c880d11e6fe29aa37c9eabfd /src/effects
parent651713408c5a5d9565665967ad09981250c7a8c9 (diff)
Leak fixed
Diffstat (limited to 'src/effects')
-rw-r--r--src/effects/SkColorCubeFilter.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/effects/SkColorCubeFilter.cpp b/src/effects/SkColorCubeFilter.cpp
index cf3126bf39..9f0d36a30d 100644
--- a/src/effects/SkColorCubeFilter.cpp
+++ b/src/effects/SkColorCubeFilter.cpp
@@ -171,9 +171,8 @@ SkColorCubeFilter::SkColorCubeFilter(SkReadBuffer& buffer)
SkFlattenable* SkColorCubeFilter::CreateProc(SkReadBuffer& buffer) {
int cubeDimension = buffer.readInt();
- SkData* cubeData = buffer.readByteArrayAsData();
+ SkAutoDataUnref cubeData(buffer.readByteArrayAsData());
if (!buffer.validate(is_valid_3D_lut(cubeData, cubeDimension))) {
- SkSafeUnref(cubeData);
return NULL;
}
return Create(cubeData, cubeDimension);