mirror of
https://github.com/servo/servo.git
synced 2025-06-10 01:23:13 +00:00
Resolves code review comments
* Lots of rust-isms * Mutable iterator for modifying entries (much better)
This commit is contained in:
parent
8086034e0b
commit
29a34dbdb5
3 changed files with 48 additions and 66 deletions
|
@ -218,10 +218,13 @@ class MachCommands(CommandBase):
|
|||
try:
|
||||
content_base64 = download_bytes("Chromium HSTS preload list", chromium_hsts_url)
|
||||
except urllib2.URLError, e:
|
||||
print("Unable to download chromium HSTS preload list, are you connected to the internet?")
|
||||
print("Unable to download chromium HSTS preload list; are you connected to the internet?")
|
||||
sys.exit(1)
|
||||
|
||||
content_decoded = base64.b64decode(content_base64)
|
||||
|
||||
# The chromium "json" has single line comments in it which, of course,
|
||||
# are non-standard/non-valid json. Simply strip them out before parsing
|
||||
content_json = re.sub(r'//.*$', '', content_decoded, flags=re.MULTILINE)
|
||||
|
||||
try:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue