On 2023/03/20 10:27, phi...@apache.org wrote:
> Author: philip
> Date: Mon Mar 20 01:27:41 2023
> New Revision: 1908547
> 
> URL: http://svn.apache.org/viewvc?rev=1908547&view=rev
> Log:
> Add SIGTERM/SIGINT handling to svnserve, this allows it to exit more
> gracefully which allows tools like valgrind to monitor whether the
> program exits cleanly and do things like leak detection.
> 
> * subversion/svnserve/svnserve.c
>   (sigtermint_handler): New handler.
>   (accept_connection): Check for signal.
>   (sub_main): Install handler, check for signal, add return.

After r1908547, svnserve shows E000004 error message even if sending
SIGTERM/SIGINT to stop normally the process.

[[[
$ ~/svn/trunk-1915316/bin/svnserve -X &
[1] 3088030
$ kill %1
$ svnserve: E000004: Can't accept client connection: Interrupted system call
]]]

Another example, the error messages are shown repeatedly while running
check-swig-rb which is using svnserve.

[[[
$ make check-swig-rb
...
Loaded suite .
Started
svnserve: E000004: Can't accept client connection: Interrupted system call
.svnserve: E000004: Can't accept client connection: Interrupted system call
.svnserve: E000004: Can't accept client connection: Interrupted system call
.svnserve: E000004: Can't accept client connection: Interrupted system call
.svnserve: E000004: Can't accept client connection: Interrupted system call
]]]

I think we should prevent the messages even if the system call is interrupted
when stop request by SIGTERM/SIGINT.

-- 
Jun Omae <jun6...@gmail.com> (大前 潤)

Reply via email to