-
Notifications
You must be signed in to change notification settings - Fork 6.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ChromeDriver] Fix array serialization when Array.toJSON is present
When web page adds toJSON function to Array prototype, ChromeDriver incorrectly calls this function while doing JSON serialization of array objects. This is incorrect, as the W3C WebDriver spec (https://w3c.github.io/webdriver/#dfn-internal-json-clone-algorithm) explicitly specifies that implementation should check for collection before looking for the toJSON function. Bug: chromedriver:3084 Change-Id: Ib2ed0c79833a6ca557d33595687efd70ade7d8c8 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1749617 Commit-Queue: John Chen <johnchen@chromium.org> Reviewed-by: Caleb Rouleau <crouleau@chromium.org> Reviewed-by: Rohan Pavone <rohpavone@chromium.org> Cr-Commit-Position: refs/heads/master@{#687307}
- Loading branch information
Showing
2 changed files
with
40 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters