8 srvaddr
= (tipc
.TIPC_ADDR_NAME
, 2000, 10, 0)
11 fd
= tipc
.socket(socket
.SOCK_STREAM
)
13 print 'server started, addr:', fd
.getsockname()
16 conn
, addr
= fd
.accept()
17 print 'connected', addr
27 evt
= tipc
.wait_for(srvaddr
, timeout
= 500)
28 if not evt
or evt
[0] == tipc
.TIPC_SUBSCR_TIMEOUT
:
31 print 'server up', evt
33 fd
= tipc
.socket(socket
.SOCK_STREAM
)
34 print 'cli ready, addr:', fd
.getsockname()
37 l
= sys
.stdin
.readline()
40 l
= sys
.stdin
.readline()