Web Replay: don't encode/decode primitive types that lack explicit sizes
authorburg@cs.washington.edu <burg@cs.washington.edu@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 24 Jul 2014 22:11:12 +0000 (22:11 +0000)
committerburg@cs.washington.edu <burg@cs.washington.edu@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 24 Jul 2014 22:11:12 +0000 (22:11 +0000)
commitd5096b138f3acad83b9cbe78236b502deaa4c390
treea818e0fc199657556b84bcf3b7310ea21e2ad647
parent026627ccfd921dad27c2a7cad019fb2c59ccdd41
Web Replay: don't encode/decode primitive types that lack explicit sizes
https://bugs.webkit.org/show_bug.cgi?id=133430

Reviewed by Anders Carlsson.

Source/JavaScriptCore:
Don't support encode/decode of unsigned long, since its size is compiler-dependent.

* replay/EncodedValue.cpp:
(JSC::EncodedValue::convertTo<unsigned long>):
(JSC::unsigned long>::encodeValue): Deleted.
* replay/EncodedValue.h:

Source/WebCore:
Remove uses of unsigned long in encode/decode methods because the type lacks an
explicit size. Move frame index serialization away from using unsigned long.

* replay/ReplayController.cpp:
(WebCore::logDispatchedDOMEvent): Fix the format string.
* replay/SerializationMethods.cpp:
(WebCore::frameIndexFromDocument):
(WebCore::frameIndexFromFrame):
(WebCore::documentFromFrameIndex):
(WebCore::frameFromFrameIndex):
(JSC::EncodingTraits<PluginData>::encodeValue):
(JSC::EncodingTraits<PluginData>::decodeValue):
* replay/SerializationMethods.h:
* replay/WebInputs.json: Remove primitive types without explicit sizes.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@171528 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/replay/EncodedValue.cpp
Source/JavaScriptCore/replay/EncodedValue.h
Source/WebCore/ChangeLog
Source/WebCore/replay/ReplayController.cpp
Source/WebCore/replay/SerializationMethods.cpp
Source/WebCore/replay/SerializationMethods.h
Source/WebCore/replay/WebInputs.json