[PATCH 1 of 4 stateful-chg] commandserver: move "listen" responsibility from service to handler

Yuya Nishihara yuya at tcha.org
Tue May 9 09:54:38 EDT 2017


On Sat, 6 May 2017 16:39:14 -0700, Jun Wu wrote:
> # HG changeset patch
> # User Jun Wu <quark at fb.com>
> # Date 1493575707 25200
> #      Sun Apr 30 11:08:27 2017 -0700
> # Node ID 9652453e198e525362e93c84712fb29c3297cf13
> # Parent  31f42e683321f225eb9c306f8d4b3a9e8d82a1da
> # Available At https://bitbucket.org/quark-zju/hg-draft
> #              hg pull https://bitbucket.org/quark-zju/hg-draft -r 9652453e198e
> commandserver: move "listen" responsibility from service to handler

Queued 1-2, thanks.

> diff --git a/mercurial/chgserver.py b/mercurial/chgserver.py
> --- a/mercurial/chgserver.py
> +++ b/mercurial/chgserver.py
> @@ -518,4 +518,5 @@ class chgunixservicehandler(object):
>          util.bindunixsocket(sock, tempaddress)
>          self._socketstat = os.stat(tempaddress)
> +        sock.listen(socket.SOMAXCONN)

Added "import socket" in flight.


More information about the Mercurial-devel mailing list