Merge changes I4b77af22,Ib5bc2de5
* changes:
Sync: Improved error message when manifest server RPC call fails
Sync: Print name of manifest server used for smart sync/smart tag
diff --git a/manifest_xml.py b/manifest_xml.py
index 817a1c8..e40e6fa 100644
--- a/manifest_xml.py
+++ b/manifest_xml.py
@@ -45,6 +45,7 @@
"""Project defaults within the manifest."""
revisionExpr = None
+ destBranchExpr = None
remote = None
sync_j = 1
sync_c = False
diff --git a/project.py b/project.py
index bc997e7..cbc3c21 100644
--- a/project.py
+++ b/project.py
@@ -1831,17 +1831,22 @@
['git-remote-persistent-https', '-print_config', url],
stdin=subprocess.PIPE, stdout=subprocess.PIPE,
stderr=subprocess.PIPE)
+ p.stdin.close() # Tell subprocess it's ok to close.
prefix = 'http.cookiefile='
+ cookiefile = None
for line in p.stdout:
line = line.strip()
if line.startswith(prefix):
- return line[len(prefix):]
+ cookiefile = line[len(prefix):]
+ break
if p.wait():
line = iter(p.stderr).next()
if ' -print_config' in line:
pass # Persistent proxy doesn't support -print_config.
else:
print(line + p.stderr.read(), file=sys.stderr)
+ if cookiefile:
+ return cookiefile
except OSError as e:
if e.errno == errno.ENOENT:
pass # No persistent proxy.