]> git.ipfire.org Git - thirdparty/git.git/commit
fsmonitor: add timeout to daemon stop command
authorPaul Tarjan <github@paulisageek.com>
Wed, 15 Apr 2026 13:27:35 +0000 (13:27 +0000)
committerJunio C Hamano <gitster@pobox.com>
Wed, 15 Apr 2026 15:44:34 +0000 (08:44 -0700)
commit1cbfa62766d04eee86d8cf0f0efe1c344e73591a
tree1d303a3c2d75d2317160ab9c7f34b7c3138d7944
parent9266aaff0aba923eb6ef08a24d413ed7052818d7
fsmonitor: add timeout to daemon stop command

The "fsmonitor--daemon stop" command polls in a loop waiting for the
daemon to exit after sending a "quit" command over IPC.  If the daemon
fails to shut down (e.g. it is stuck or wedged), this loop spins
forever.

Add a 30-second timeout so the stop command returns an error instead
of blocking indefinitely.

Signed-off-by: Paul Tarjan <github@paulisageek.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/fsmonitor--daemon.c