From fabbac885f2d60fa05c4ff24927a0554394f430b Mon Sep 17 00:00:00 2001
From: Brandon Heller <brandonh@stanford.edu>
Date: Sat, 19 Dec 2009 19:21:18 -0800
Subject: [PATCH] Document retry function

---
 mininet/mininet.py | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/mininet/mininet.py b/mininet/mininet.py
index 6da7ba80..36a48bfb 100755
--- a/mininet/mininet.py
+++ b/mininet/mininet.py
@@ -399,7 +399,13 @@ def moveIntf( intf, node, print_error = False ):
    return True
 
 def retry( n, retry_delay, fn, *args):
-   "Try something N times before giving up."
+   '''Try something N times before giving up.
+
+   @param n number of times to retry
+   @param retry_delay seconds wait this long between tries
+   @param fn function to call
+   @param args args to apply to function call
+   '''
    tries = 0
    while not apply( fn, args ) and tries < n:
       sleep( retry_delay )
-- 
GitLab