Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
gamepad: Check that the DocumentLoader is not null
Gamepad timestamps are reported relative to the navigationStart timestamp, accessed from the DocumentLoader's DocumentLoadTiming. In some scenarios the document may have been detached before the NavigatorGamepad is initialized, causing the DocumentLoader to be nullptr. This CL checks that the DocumentLoader is non-null, and uses the current time in place of navigationStart if it is null. Bug: 1483777 Change-Id: Ib3efcf3a612cd4c1c543218fa5fb8568c7129dcf Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4899018 Reviewed-by: Alvin Ji <[email protected]> Commit-Queue: Matt Reynolds <[email protected]> Cr-Commit-Position: refs/heads/main@{#1204813}
- Loading branch information