From 7ba9e055420644779d493a3e063ac4674a1816e0 Mon Sep 17 00:00:00 2001 From: Bob Lantz <rlantz@cs.stanford.edu> Date: Mon, 8 Mar 2010 15:36:09 -0800 Subject: [PATCH] Fixed errors due to renaming buffer to buf. --- examples/udpbwtest.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/udpbwtest.py b/examples/udpbwtest.py index 74dcda5a..9832d18c 100755 --- a/examples/udpbwtest.py +++ b/examples/udpbwtest.py @@ -35,8 +35,8 @@ def readline( host, buf ): "Read a line from a host, buffering with buffer." buf += host.read( 1024 ) - if '\n' not in buffer: - return None, buffer + if '\n' not in buf: + return None, buf pos = buf.find( '\n' ) line = buf[ 0 : pos ] rest = buf[ pos + 1: ] @@ -130,7 +130,7 @@ def udpbwtest( net, seconds ): printTotalHeader() times = sorted( results.keys() ) for t in times: - printTotal( t - t[ 0 ] , results[ t ] ) + printTotal( t - times[ 0 ] , results[ t ] ) print # pylint: enable-msg=E1101 -- GitLab