mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-16 05:51:55 +00:00
LibWeb: Reserve zero for not supported transfer type
Previously we were using 0 for both unsupported type and MessagePort, which led to crashing on attempt to decode unsupported transfer type as MessagePort. Fixes crashing on https://docs.mapbox.com/mapbox-gl-js/clip-layer-building-demo.html
This commit is contained in:
parent
e18e7d6019
commit
ea8a6b43f7
Notes:
github-actions[bot]
2025-04-14 15:02:44 +00:00
Author: https://github.com/kalenikaliaksandr
Commit: ea8a6b43f7
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4342
Reviewed-by: https://github.com/trflynn89
3 changed files with 10 additions and 5 deletions
|
@ -45,9 +45,10 @@ struct DeserializedRecord {
|
|||
};
|
||||
|
||||
enum class TransferType : u8 {
|
||||
MessagePort,
|
||||
ArrayBuffer,
|
||||
ResizableArrayBuffer,
|
||||
Unknown = 0,
|
||||
MessagePort = 1,
|
||||
ArrayBuffer = 2,
|
||||
ResizableArrayBuffer = 3,
|
||||
};
|
||||
|
||||
WebIDL::ExceptionOr<SerializationRecord> structured_serialize(JS::VM& vm, JS::Value);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue