DescriptionCause:
From the user agent strings in our server logs, the offending user agents are
Morzilla/5.0 (X11; CrOS x86_64 6457.107.0)
which fails to match
'CrOS ([a-zA-Z0-9]*) ([0-9.]*)'
because _ is missing in the first match group.
This CL:
1. Fixes the regular expression.
2. Unifies the duplicated platform detection logic in our logs and platform.js
3. Implements an unit test using key examples from the server logs as test cases.
BUG=495206
Committed: https://crrev.com/e989257af8a63fa4e5780635259b04663247ab5b
Cr-Commit-Position: refs/heads/master@{#333208}
Patch Set 1 #
Total comments: 7
Patch Set 2 : Reviewer's feedback #
Messages
Total messages: 9 (3 generated)
|