Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(399)

Side by Side Diff: chrome/test/data/safe_browsing/download_update.py

Issue 507067: Add some licensing comments under chrome/. (Closed)
Patch Set: Created 11 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/python
2 # Copyright (c) 2009 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file.
2 5
3 import urllib,sys 6 import urllib,sys
4 7
5 8
6 url = 'http://safebrowsing.clients.google.com/safebrowsing/downloads?client=goog leclient&appver=1.0&pver=2.1' 9 url = 'http://safebrowsing.clients.google.com/safebrowsing/downloads?client=goog leclient&appver=1.0&pver=2.1'
7 10
8 if len(sys.argv) == 1: 11 if len(sys.argv) == 1:
9 data = 'goog-phish-shavar;\ngoog-malware-shavar;\n' 12 data = 'goog-phish-shavar;\ngoog-malware-shavar;\n'
10 else: 13 else:
11 post_data_file = sys.argv[1] 14 post_data_file = sys.argv[1]
(...skipping 14 matching lines...) Expand all
26 continue 29 continue
27 30
28 chunk_url = 'http://' + line[2:] 31 chunk_url = 'http://' + line[2:]
29 filename = chunk_url[chunk_url.rfind('/') + 1:] 32 filename = chunk_url[chunk_url.rfind('/') + 1:]
30 filename = "%03d" % counter + filename[0:filename.rfind('_')] 33 filename = "%03d" % counter + filename[0:filename.rfind('_')]
31 counter += 1 34 counter += 1
32 35
33 urllib.urlretrieve(chunk_url, filename) 36 urllib.urlretrieve(chunk_url, filename)
34 37
35 response_file.close() 38 response_file.close()
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698