Title: [225759] trunk/Source/WebKit
- Revision
- 225759
- Author
- [email protected]
- Date
- 2017-12-11 15:23:52 -0800 (Mon, 11 Dec 2017)
Log Message
RTCPacketOptions::packet_id should be encoded as 32 bits integer.
https://bugs.webkit.org/show_bug.cgi?id=180654
Patch by Youenn Fablet <[email protected]> on 2017-12-11
Reviewed by Eric Carlson.
packet_id is a 16 bit unsigned integer, but it can also take -1 if its value is not set.
Before the patch, it was IPC encoded as a 16 bit signed integer which is not large enough.
* Shared/RTCPacketOptions.cpp:
(WebKit::RTCPacketOptions::encode const):
(WebKit::RTCPacketOptions::decode):
Modified Paths
Diff
Modified: trunk/Source/WebKit/ChangeLog (225758 => 225759)
--- trunk/Source/WebKit/ChangeLog 2017-12-11 22:49:10 UTC (rev 225758)
+++ trunk/Source/WebKit/ChangeLog 2017-12-11 23:23:52 UTC (rev 225759)
@@ -1,3 +1,17 @@
+2017-12-11 Youenn Fablet <[email protected]>
+
+ RTCPacketOptions::packet_id should be encoded as 32 bits integer.
+ https://bugs.webkit.org/show_bug.cgi?id=180654
+
+ Reviewed by Eric Carlson.
+
+ packet_id is a 16 bit unsigned integer, but it can also take -1 if its value is not set.
+ Before the patch, it was IPC encoded as a 16 bit signed integer which is not large enough.
+
+ * Shared/RTCPacketOptions.cpp:
+ (WebKit::RTCPacketOptions::encode const):
+ (WebKit::RTCPacketOptions::decode):
+
2017-12-11 Chris Dumez <[email protected]>
Layout Test http/tests/workers/service/postmessage-after-sw-process-crash.https.html is flaky
Modified: trunk/Source/WebKit/Shared/RTCPacketOptions.cpp (225758 => 225759)
--- trunk/Source/WebKit/Shared/RTCPacketOptions.cpp 2017-12-11 22:49:10 UTC (rev 225758)
+++ trunk/Source/WebKit/Shared/RTCPacketOptions.cpp 2017-12-11 23:23:52 UTC (rev 225759)
@@ -36,7 +36,7 @@
void RTCPacketOptions::encode(IPC::Encoder& encoder) const
{
encoder.encodeEnum(options.dscp);
- encoder << safeCast<int16_t>(options.packet_id);
+ encoder << safeCast<int32_t>(options.packet_id);
encoder << options.packet_time_params.rtp_sendtime_extension_id;
encoder << static_cast<int64_t>(options.packet_time_params.srtp_auth_tag_len);
@@ -56,7 +56,7 @@
return std::nullopt;
options.dscp = dscp;
- std::optional<int16_t> packetId;
+ std::optional<int32_t> packetId;
decoder >> packetId;
if (!packetId)
return std::nullopt;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes