summaryrefslogtreecommitdiffstats
path: root/Demo/sockets/udpecho.py
diff options
context:
space:
mode:
Diffstat (limited to 'Demo/sockets/udpecho.py')
-rwxr-xr-xDemo/sockets/udpecho.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Demo/sockets/udpecho.py b/Demo/sockets/udpecho.py
index 4410165..720cfe1 100755
--- a/Demo/sockets/udpecho.py
+++ b/Demo/sockets/udpecho.py
@@ -37,7 +37,7 @@ def server():
print 'udp echo server ready'
while 1:
data, addr = s.recvfrom(BUFSIZE)
- print 'server received', `data`, 'from', `addr`
+ print 'server received %r from %r' % (data, addr)
s.sendto(data, addr)
def client():
@@ -58,6 +58,6 @@ def client():
break
s.sendto(line, addr)
data, fromaddr = s.recvfrom(BUFSIZE)
- print 'client received', `data`, 'from', `fromaddr`
+ print 'client received %r from %r' % (data, fromaddr)
main()