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

Side by Side Diff: tools/generate_bad_x86_64_nexes.py

Issue 12450015: **/*.py: use /usr/bin/env to find python Base URL: https://chromium.googlesource.com/native_client/src/native_client@master
Patch Set: Created 7 years, 9 months 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
« no previous file with comments | « tools/generate_bad_nexes.py ('k') | tools/httpd.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/env python
2 # 2 #
3 # Copyright 2010 The Native Client Authors. All rights reserved. Use 3 # Copyright 2010 The Native Client Authors. All rights reserved. Use
4 # of this source code is governed by a BSD-style license that can be 4 # of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 # 6 #
7 # This tool generates bad x86_64 NaCl modules that should never be 7 # This tool generates bad x86_64 NaCl modules that should never be
8 # generated by a conformant compiler. These bad modules are used to 8 # generated by a conformant compiler. These bad modules are used to
9 # test that sel_ldr correctly detects that these are bad modules. 9 # test that sel_ldr correctly detects that these are bad modules.
10 # 10 #
11 # The detailed info about the fib_scalar.nexe used as input: 11 # The detailed info about the fib_scalar.nexe used as input:
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 186
187 def UpdateFileWithChangeList(src_file, dst_file, change_list): 187 def UpdateFileWithChangeList(src_file, dst_file, change_list):
188 data = open(src_file).read() 188 data = open(src_file).read()
189 data = UpdateData(data, change_list) 189 data = UpdateData(data, change_list)
190 open(dst_file, 'w').write(data) 190 open(dst_file, 'w').write(data)
191 191
192 if __name__ == '__main__': 192 if __name__ == '__main__':
193 for src_file, dst_file, cl in FILE_MODIFICATIONS: 193 for src_file, dst_file, cl in FILE_MODIFICATIONS:
194 UpdateFileWithChangeList(src_file, dst_file, cl) 194 UpdateFileWithChangeList(src_file, dst_file, cl)
195 sys.exit(0) 195 sys.exit(0)
OLDNEW
« no previous file with comments | « tools/generate_bad_nexes.py ('k') | tools/httpd.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698