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

Unified Diff: include/core/SkReadBuffer.h

Issue 240013005: read/write function_ptrs as just void*, and not as 'array of bytes' (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | include/core/SkWriteBuffer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkReadBuffer.h
diff --git a/include/core/SkReadBuffer.h b/include/core/SkReadBuffer.h
index 3cb31a0e809c2e2f9b61e8f912d370f544f3f66d..f6b1919133a2307764bb743e035e6b84f645067e 100644
--- a/include/core/SkReadBuffer.h
+++ b/include/core/SkReadBuffer.h
@@ -73,6 +73,7 @@ public:
uint32_t offset() { return fReader.offset(); }
bool eof() { return fReader.eof(); }
const void* skip(size_t size) { return fReader.skip(size); }
+ void* readFunctionPtr() { return fReader.readPtr(); }
bungeman-skia 2014/04/16 16:51:36 So, I think this was 'incorrect' before, so this c
// primitives
virtual bool readBool();
@@ -83,12 +84,6 @@ public:
virtual uint32_t readUInt();
virtual int32_t read32();
- void* readFunctionPtr() {
- void* ptr;
- this->readByteArray(&ptr, sizeof(ptr));
- return ptr;
- }
-
// strings -- the caller is responsible for freeing the string contents
virtual void readString(SkString* string);
virtual void* readEncodedString(size_t* length, SkPaint::TextEncoding encoding);
« no previous file with comments | « no previous file | include/core/SkWriteBuffer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698