summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--pym/emerge/__init__.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/pym/emerge/__init__.py b/pym/emerge/__init__.py
index 5a1fedbd4..10dfe9d3c 100644
--- a/pym/emerge/__init__.py
+++ b/pym/emerge/__init__.py
@@ -3983,7 +3983,12 @@ def action_sync(settings, trees, mtimedb, myopts, myaction):
exitcode = os.EX_OK
servertimestamp = 0
- if mytimestamp != 0:
+ # Even if there's no timestamp available locally, fetch the
+ # timestamp anyway as an initial probe to verify that the server is
+ # responsive. This protects us from hanging indefinitely on a
+ # connection attempt to an unresponsive server which rsync's
+ # --timeout option does not prevent.
+ if True:
mycommand = rsynccommand.split()
mycommand.append(dosyncuri.rstrip("/") + \
"/metadata/timestamp.chk")