dirty...dirty..dirty hack to get rid of r2q.
authorFaiyaz Ahmed <faiyaza@cs.princeton.edu>
Thu, 29 Jan 2009 20:45:52 +0000 (20:45 +0000)
committerFaiyaz Ahmed <faiyaza@cs.princeton.edu>
Thu, 29 Jan 2009 20:45:52 +0000 (20:45 +0000)
python/bwlimit.py

index 7b3cf05..58d3052 100644 (file)
@@ -325,7 +325,10 @@ def stop(dev = dev):
     '''
     Turn off all queing.  Stops all slice HTBS and reverts to pfifo_fast (the default).
     '''
     '''
     Turn off all queing.  Stops all slice HTBS and reverts to pfifo_fast (the default).
     '''
-    tc("qdisc del dev %s root" % dev)
+    try:
+        for i in range(0,2):
+            tc("qdisc del dev %s root" % dev)
+    except: pass
 
 
 def init(dev = dev, bwcap = bwmax):
 
 
 def init(dev = dev, bwcap = bwmax):