receiver.py 209 Bytes
Newer Older
1
2
3
4
5
import sys
import prrt

port = int(sys.argv[1])

6
s = prrt.PrrtSocket(port=port)
7
8

while True:
9
10
    d, addr = s.recv()
    d = d.decode("utf8")
11
    if d != "Close":
12
        print(d, addr)
13
14
    else:
        break