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

Unified Diff: presubmit_support.py

Issue 238603002: Added implicit empty password to 'presubmit_support.py' (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: Created 6 years, 8 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: presubmit_support.py
diff --git a/presubmit_support.py b/presubmit_support.py
index f39d8212e9729e71f215e8f3e5fb68aad10f9e73..6b69145db4ab39b61326ee71085e0a73f45f76d7 100755
--- a/presubmit_support.py
+++ b/presubmit_support.py
@@ -1559,9 +1559,14 @@ def Main(argv):
if options.rietveld_email and options.rietveld_email_file:
parser.error("Only one of --rietveld_email or --rietveld_email_file "
"can be passed to this program.")
- if options.rietveld_private_key_file and options.rietveld_password:
- parser.error("Only one of --rietveld_private_key_file or "
- "--rietveld_password can be passed to this program.")
+ if options.rietveld_private_key_file:
+ if options.rietveld_password:
+ parser.error("Only one of --rietveld_private_key_file or "
+ "--rietveld_password can be passed to this program.")
+ elif not options.rietveld_password:
nodir 2014/04/15 03:16:47 I would be more explicit: options.rietveld_passw
+ # Default to empty password if neither e-mail nor password is supplied
+ options.rietveld_password = ''
+
if options.rietveld_email_file:
with open(options.rietveld_email_file, "rb") as f:
options.rietveld_email = f.read().strip()
« 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