(process, sid, max_read_bytes, win_emit_output=True)
| 227 | |
| 228 | |
| 229 | def read_stdout(process, sid, max_read_bytes, win_emit_output=True): |
| 230 | (data_ready, _, _) = select.select([process.fd], [], [], 0) |
| 231 | if process.fd in data_ready: |
| 232 | output = process.read(max_read_bytes) |
| 233 | if win_emit_output: |
| 234 | sio.emit('pty-output', |
| 235 | {'result': output, |
| 236 | 'error': False}, |
| 237 | namespace='/pty', room=sid) |
| 238 | |
| 239 | sio.sleep(0.01) |
| 240 | |
| 241 | |
| 242 | def windows_platform(connection_data, sid, max_read_bytes, server_id): |
no test coverage detected