Index: src/pdf/SkPDFShader.cpp |
diff --git a/src/pdf/SkPDFShader.cpp b/src/pdf/SkPDFShader.cpp |
index 8fc97da30770153029a1e08fd461adb89e537d9d..97bca73f63b78d33c5e552736e4702f015277646 100644 |
--- a/src/pdf/SkPDFShader.cpp |
+++ b/src/pdf/SkPDFShader.cpp |
@@ -877,7 +877,8 @@ SkPDFFunctionShader* SkPDFFunctionShader::Create( |
pdfShader->insertName("ColorSpace", "DeviceRGB"); |
pdfShader->insert("Domain", domain.get()); |
- SkPDFStream* function = make_ps_function(functionCode, domain.get()); |
+ SkAutoTUnref<SkPDFStream> function( |
+ make_ps_function(functionCode, domain.get())); |
pdfShader->insert("Function", new SkPDFObjRef(function))->unref(); |
SkAutoTUnref<SkPDFArray> matrixArray( |