Fix double->int conversion in ParseJSON
The previous code was triggering undefined behaviour by casting a double to an int without testing whether it actually fit within the limits of an int. This was causing incorrect code to be emitted by recent versions of Clang on ARM64. Bug: 851415 Change-Id: Ie40ded6d11377f05c92713165441324f33ac6db3 Reviewed-on: https://chromium-review.googlesource.com/1096028Reviewed-by:Daniel Cheng <dcheng@chromium.org> Commit-Queue: Ian Clelland <iclelland@chromium.org> Cr-Commit-Position: refs/heads/master@{#566314}
Showing
Please register or sign in to comment