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

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

Issue 1265033002: IWYU: 'core' target, files starting A-C. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Rebase (a file was deleted). Created 5 years, 4 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/SkBuffer.h ('k') | src/core/SkCachedData.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
2 /* 1 /*
3 * Copyright 2006 The Android Open Source Project 2 * Copyright 2006 The Android Open Source Project
4 * 3 *
5 * 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
6 * found in the LICENSE file. 5 * found in the LICENSE file.
7 */ 6 */
8 7
8 #include "SkBuffer.h"
9 9
10 #include "SkBuffer.h" 10 #include <string.h>
11 11
12 //////////////////////////////////////////////////////////////////////////////// //////// 12 //////////////////////////////////////////////////////////////////////////////// ////////
13 13
14 void SkRBuffer::readNoSizeCheck(void* buffer, size_t size) 14 void SkRBuffer::readNoSizeCheck(void* buffer, size_t size)
15 { 15 {
16 SkASSERT((fData != 0 && fStop == 0) || fPos + size <= fStop); 16 SkASSERT((fData != 0 && fStop == 0) || fPos + size <= fStop);
17 if (buffer) 17 if (buffer)
18 memcpy(buffer, fPos, size); 18 memcpy(buffer, fPos, size);
19 fPos += size; 19 fPos += size;
20 } 20 }
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 128
129 const void* sk_buffer_read_ptr(const void* buffer, void** ptr) 129 const void* sk_buffer_read_ptr(const void* buffer, void** ptr)
130 { 130 {
131 AssertBuffer32(buffer); 131 AssertBuffer32(buffer);
132 if (ptr) 132 if (ptr)
133 *ptr = *(void**)buffer; 133 *ptr = *(void**)buffer;
134 return (const char*)buffer + sizeof(void*); 134 return (const char*)buffer + sizeof(void*);
135 } 135 }
136 136
137 #endif 137 #endif
OLDNEW
« no previous file with comments | « src/core/SkBuffer.h ('k') | src/core/SkCachedData.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698