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

Unified Diff: trychange.py

Issue 10815009: gclient_utils.FileWrite() assumes text data but trychange doesn't. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: Created 8 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trychange.py
diff --git a/trychange.py b/trychange.py
index 4a29aecd6ba1bce36171f8f46337ee277572932b..ceeeecea9b681af9a92f6988600f1050da6db10a 100755
--- a/trychange.py
+++ b/trychange.py
@@ -399,7 +399,8 @@ def _SendChangeSVN(options):
file_name = (Escape(options.user) + '.' + Escape(options.name) +
'.%s.diff' % current_time)
full_path = os.path.join(temp_dir, file_name)
- gclient_utils.FileWrite(full_path, options.diff, 'wb')
+ with open(full_path, 'wb') as f:
+ f.write(options.diff)
# Committing it will trigger a try job.
if sys.platform == "cygwin":
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698