OLD | NEW |
1 from mod_pywebsocket import common | 1 from mod_pywebsocket import common |
2 from mod_pywebsocket import stream | 2 from mod_pywebsocket import stream |
3 | 3 |
4 | 4 |
5 def web_socket_do_extra_handshake(request): | 5 def web_socket_do_extra_handshake(request): |
6 pass | 6 pass |
7 | 7 |
8 | 8 |
9 def web_socket_transfer_data(request): | 9 def web_socket_transfer_data(request): |
10 # All control frames must have a payload length of 125 bytes or less. | 10 # All control frames must have a payload length of 125 bytes or less. |
11 message = 'X' * 126 | 11 message = 'X' * 126 |
12 request.connection.write(stream.create_text_frame(message, opcode=common.OPC
ODE_PING, fin=1)) | 12 request.connection.write(stream.create_text_frame(message, opcode=common.OPC
ODE_PING, fin=1)) |
OLD | NEW |