Report len(ips) as max retry count for --sync.
authorZac Medico <zmedico@gentoo.org>
Thu, 7 Oct 2010 15:22:47 +0000 (08:22 -0700)
committerZac Medico <zmedico@gentoo.org>
Thu, 7 Oct 2010 15:26:36 +0000 (08:26 -0700)
pym/_emerge/actions.py

index 322e4d4979844170b0d4f33f32e5460f9d64cd32..1866cf9c07c00fc44110180ff229899b735a3158 100644 (file)
@@ -2141,10 +2141,15 @@ def action_sync(settings, trees, mtimedb, myopts, myaction):
                                if "--quiet" not in myopts:
                                        print(">>> Starting rsync with "+dosyncuri+"...")
                        else:
+                               effective_maxretries = maxretries
+                               if effective_maxretries < 0:
+                                       effective_maxretries = len(ips)
                                emergelog(xterm_titles,
                                        ">>> Starting retry %d of %d with %s" % \
-                                               (retries,maxretries,dosyncuri))
-                               print("\n\n>>> Starting retry %d of %d with %s" % (retries,maxretries,dosyncuri))
+                                               (retries, effective_maxretries, dosyncuri))
+                               writemsg_stdout(
+                                       "\n\n>>> Starting retry %d of %d with %s\n" % \
+                                       (retries, effective_maxretries, dosyncuri), noiselevel=-1)
 
                        if mytimestamp != 0 and "--quiet" not in myopts:
                                print(">>> Checking server timestamp ...")