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

Side by Side Diff: src/core/SkReadBuffer.cpp

Issue 1893423002: Fix ImageFilter fuzzer issue (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Remove setOffset Created 4 years, 8 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 unified diff | Download patch
« no previous file with comments | « src/core/SkReadBuffer.h ('k') | src/core/SkValidatingReadBuffer.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2012 Google Inc. 2 * Copyright 2012 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkBitmap.h" 8 #include "SkBitmap.h"
9 #include "SkErrorInternals.h" 9 #include "SkErrorInternals.h"
10 #include "SkImage.h" 10 #include "SkImage.h"
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 } 131 }
132 132
133 void SkReadBuffer::readIRect(SkIRect* rect) { 133 void SkReadBuffer::readIRect(SkIRect* rect) {
134 memcpy(rect, fReader.skip(sizeof(SkIRect)), sizeof(SkIRect)); 134 memcpy(rect, fReader.skip(sizeof(SkIRect)), sizeof(SkIRect));
135 } 135 }
136 136
137 void SkReadBuffer::readRect(SkRect* rect) { 137 void SkReadBuffer::readRect(SkRect* rect) {
138 memcpy(rect, fReader.skip(sizeof(SkRect)), sizeof(SkRect)); 138 memcpy(rect, fReader.skip(sizeof(SkRect)), sizeof(SkRect));
139 } 139 }
140 140
141 void SkReadBuffer::readRRect(SkRRect* rrect) {
142 fReader.readRRect(rrect);
143 }
144
141 void SkReadBuffer::readRegion(SkRegion* region) { 145 void SkReadBuffer::readRegion(SkRegion* region) {
142 fReader.readRegion(region); 146 fReader.readRegion(region);
143 } 147 }
144 148
145 void SkReadBuffer::readPath(SkPath* path) { 149 void SkReadBuffer::readPath(SkPath* path) {
146 fReader.readPath(path); 150 fReader.readPath(path);
147 } 151 }
148 152
149 bool SkReadBuffer::readArray(void* value, size_t size, size_t elementSize) { 153 bool SkReadBuffer::readArray(void* value, size_t size, size_t elementSize) {
150 const size_t count = this->getArrayCount(); 154 const size_t count = this->getArrayCount();
(...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after
380 return; 384 return;
381 } 385 }
382 } else { 386 } else {
383 if (nullptr == this->readFunctionPtr()) { 387 if (nullptr == this->readFunctionPtr()) {
384 return; 388 return;
385 } 389 }
386 } 390 }
387 uint32_t sizeRecorded = fReader.readU32(); 391 uint32_t sizeRecorded = fReader.readU32();
388 fReader.skip(sizeRecorded); 392 fReader.skip(sizeRecorded);
389 } 393 }
OLDNEW
« no previous file with comments | « src/core/SkReadBuffer.h ('k') | src/core/SkValidatingReadBuffer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698