Index: src/pdf/SkPDFResourceDict.cpp |
diff --git a/src/pdf/SkPDFResourceDict.cpp b/src/pdf/SkPDFResourceDict.cpp |
index 460d18c74077a92182e8934b618c300ac0913f52..d3f4a6d53347d29c36518e0c18cfd105f86cad23 100644 |
--- a/src/pdf/SkPDFResourceDict.cpp |
+++ b/src/pdf/SkPDFResourceDict.cpp |
@@ -61,7 +61,7 @@ static void add_subdict( |
if (0 == resourceList.count()) { |
return; |
} |
- sk_sp<SkPDFDict> resources(new SkPDFDict); |
+ auto resources = sk_make_sp<SkPDFDict>(); |
for (int i = 0; i < resourceList.count(); i++) { |
resources->insertObjRef(SkPDFResourceDict::getResourceName(type, i), |
SkRef(resourceList[i])); |
@@ -74,10 +74,10 @@ SkPDFDict* SkPDFResourceDict::Create( |
const SkTDArray<SkPDFObject*>* patternResources, |
const SkTDArray<SkPDFObject*>* xObjectResources, |
const SkTDArray<SkPDFObject*>* fontResources) { |
- sk_sp<SkPDFDict> dict(new SkPDFDict); |
+ auto dict = sk_make_sp<SkPDFDict>(); |
static const char kProcs[][7] = { |
"PDF", "Text", "ImageB", "ImageC", "ImageI"}; |
- sk_sp<SkPDFArray> procSets(new SkPDFArray); |
+ auto procSets = sk_make_sp<SkPDFArray>(); |
procSets->reserve(SK_ARRAY_COUNT(kProcs)); |
for (size_t i = 0; i < SK_ARRAY_COUNT(kProcs); i++) { |