diff options
author | Paul Sokolovsky <paul.sokolovsky@linaro.org> | 2016-01-12 21:59:29 +0200 |
---|---|---|
committer | Paul Sokolovsky <paul.sokolovsky@linaro.org> | 2016-01-12 21:59:29 +0200 |
commit | 46731a8a9108dae9e898a5fcfdad2db9235c6a9a (patch) | |
tree | cc7c608bed2ff0852a89c0cfacf2f7264ad3cfc7 | |
parent | 8097341492c03b41634e9fe97330c66efedc58f8 (diff) |
linaro_gerrit.py: apply_gerrit_conf(): Don't override command-line opts.
I.e. work per the spec in the docstring. Override only options whose value
is None after parsing command line. This is true for string-valued options
not set on command line, but may be not true for other options.
Change-Id: Ib63020922f908fd8ff9f936c04e47bc827582a91
-rwxr-xr-x | linaro_gerrit.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/linaro_gerrit.py b/linaro_gerrit.py index c5fef05..7c654ec 100755 --- a/linaro_gerrit.py +++ b/linaro_gerrit.py @@ -189,5 +189,5 @@ def apply_gerrit_conf(args): if not l or l[0] == "#": continue k, v = [x.strip() for x in l.split("=", 1)] - if hasattr(args, k): + if hasattr(args, k) and getattr(args, k) is None: setattr(args, k, v) |