Index: src/pdf/SkPDFFont.cpp |
diff --git a/src/pdf/SkPDFFont.cpp b/src/pdf/SkPDFFont.cpp |
index 08c1289ce361b8f3fa1b3bbf34c0f66badf28547..bdd83efe28129f42b618a7a47c18fedade38a551 100644 |
--- a/src/pdf/SkPDFFont.cpp |
+++ b/src/pdf/SkPDFFont.cpp |
@@ -157,7 +157,7 @@ static SkData* handle_type1_stream(SkStream* srcStream, size_t* headerLen, |
// if the data was NUL terminated so that we can use strstr() to search it. |
// Make as few copies as possible given these constraints. |
SkDynamicMemoryWStream dynamicStream; |
- SkAutoTUnref<SkMemoryStream> staticStream; |
+ SkAutoTDelete<SkMemoryStream> staticStream; |
SkData* data = NULL; |
const uint8_t* src; |
size_t srcLen; |
@@ -585,7 +585,7 @@ static size_t get_subset_font_stream(const char* fontName, |
const SkTDArray<uint32_t>& subset, |
SkPDFStream** fontStream) { |
int ttcIndex; |
- SkAutoTUnref<SkStream> fontData(typeface->openStream(&ttcIndex)); |
+ SkAutoTDelete<SkStream> fontData(typeface->openStream(&ttcIndex)); |
SkASSERT(fontData.get()); |
size_t fontSize = fontData->getLength(); |
@@ -1161,7 +1161,7 @@ bool SkPDFCIDFont::addFontDescriptor(int16_t defaultWidth, |
fontStream.reset(rawStream); |
} else { |
int ttcIndex; |
- SkAutoTUnref<SkStream> fontData( |
+ SkAutoTDelete<SkStream> fontData( |
typeface()->openStream(&ttcIndex)); |
fontStream.reset(new SkPDFStream(fontData.get())); |
fontSize = fontData->getLength(); |
@@ -1178,7 +1178,7 @@ bool SkPDFCIDFont::addFontDescriptor(int16_t defaultWidth, |
case SkAdvancedTypefaceMetrics::kCFF_Font: |
case SkAdvancedTypefaceMetrics::kType1CID_Font: { |
int ttcIndex; |
- SkAutoTUnref<SkStream> fontData(typeface()->openStream(&ttcIndex)); |
+ SkAutoTDelete<SkStream> fontData(typeface()->openStream(&ttcIndex)); |
SkAutoTUnref<SkPDFStream> fontStream( |
new SkPDFStream(fontData.get())); |
addResource(fontStream.get()); |
@@ -1308,7 +1308,7 @@ bool SkPDFType1Font::addFontDescriptor(int16_t defaultWidth) { |
size_t header SK_INIT_TO_AVOID_WARNING; |
size_t data SK_INIT_TO_AVOID_WARNING; |
size_t trailer SK_INIT_TO_AVOID_WARNING; |
- SkAutoTUnref<SkStream> rawFontData(typeface()->openStream(&ttcIndex)); |
+ SkAutoTDelete<SkStream> rawFontData(typeface()->openStream(&ttcIndex)); |
SkAutoTUnref<SkData> fontData(handle_type1_stream(rawFontData.get(), &header, |
&data, &trailer)); |
if (fontData.get() == NULL) { |
@@ -1475,7 +1475,7 @@ bool SkPDFType3Font::populate(uint16_t glyphID) { |
SkPDFUtils::PaintPath(paint.getStyle(), path->getFillType(), |
&content); |
} |
- SkAutoTUnref<SkMemoryStream> glyphStream(new SkMemoryStream()); |
+ SkAutoTDelete<SkMemoryStream> glyphStream(new SkMemoryStream()); |
glyphStream->setData(content.copyToData())->unref(); |
SkAutoTUnref<SkPDFStream> glyphDescription( |