Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(150)

Unified Diff: src/core/SkFlattenableSerialization.cpp

Issue 138803005: Set write buffer flags only in SkWriteBuffer and SkFlatController constructors. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: INHERITED Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « include/core/SkWriteBuffer.h ('k') | src/core/SkPictureFlat.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkFlattenableSerialization.cpp
diff --git a/src/core/SkFlattenableSerialization.cpp b/src/core/SkFlattenableSerialization.cpp
index 13fbe6edbf9b0368c13eeb36d67d3c015962a9f9..f34e64170cbb687ec72a3c63049145b237915838 100644
--- a/src/core/SkFlattenableSerialization.cpp
+++ b/src/core/SkFlattenableSerialization.cpp
@@ -12,8 +12,7 @@
#include "SkWriteBuffer.h"
SkData* SkValidatingSerializeFlattenable(SkFlattenable* flattenable) {
- SkWriteBuffer writer;
- writer.setFlags(SkWriteBuffer::kValidation_Flag);
+ SkWriteBuffer writer(SkWriteBuffer::kValidation_Flag);
writer.writeFlattenable(flattenable);
uint32_t size = writer.bytesWritten();
void* data = sk_malloc_throw(size);
« no previous file with comments | « include/core/SkWriteBuffer.h ('k') | src/core/SkPictureFlat.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698