Commit eba12e2e authored by David Wilson's avatar David Wilson

issue #139: bump kernel socket buffer size to 128kb

This allows us to write 128kb at a time towards SSH, but it doesn't help
with sudo, where the ancient tty layer is always used.
parent 728a0da8
......@@ -123,6 +123,12 @@ def close_nonstandard_fds():
def create_child(*args):
parentfp, childfp = socket.socketpair()
parentfp.setsockopt(socket.SOL_SOCKET,
socket.SO_SNDBUF,
mitogen.core.CHUNK_SIZE)
childfp.setsockopt(socket.SOL_SOCKET,
socket.SO_RCVBUF,
mitogen.core.CHUNK_SIZE)
pid = os.fork()
if not pid:
mitogen.core.set_block(childfp.fileno())
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment