diff options
| author | Taylor Blau <me@ttaylorr.com> | 2024-10-15 16:56:43 -0400 |
|---|---|---|
| committer | Taylor Blau <me@ttaylorr.com> | 2024-10-15 16:56:43 -0400 |
| commit | b43e23fa02427067ceb605a5dd5ea602de4c6ac5 (patch) | |
| tree | f3807a33e9cd06c829fdb1262a52eeb594f81920 /builtin/fsmonitor--daemon.c | |
| parent | Merge branch 'xx/remote-server-option-config' (diff) | |
| parent | fsmonitor: initialize fs event listener before accepting clients (diff) | |
| download | git-b43e23fa02427067ceb605a5dd5ea602de4c6ac5.tar.gz git-b43e23fa02427067ceb605a5dd5ea602de4c6ac5.zip | |
Merge branch 'jk/fsmonitor-event-listener-race-fix'
On macOS, fsmonitor can fall into a race condition that results in
a client waiting forever to be notified for an event that have
already happened. This problem has been corrected.
* jk/fsmonitor-event-listener-race-fix:
fsmonitor: initialize fs event listener before accepting clients
simple-ipc: split async server initialization and running
Diffstat (limited to 'builtin/fsmonitor--daemon.c')
| -rw-r--r-- | builtin/fsmonitor--daemon.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/builtin/fsmonitor--daemon.c b/builtin/fsmonitor--daemon.c index e1e6b96d09..f3f6bd330b 100644 --- a/builtin/fsmonitor--daemon.c +++ b/builtin/fsmonitor--daemon.c @@ -1208,9 +1208,9 @@ static int fsmonitor_run_daemon_1(struct fsmonitor_daemon_state *state) * system event listener thread so that we have the IPC handle * before we need it. */ - if (ipc_server_run_async(&state->ipc_server_data, - state->path_ipc.buf, &ipc_opts, - handle_client, state)) + if (ipc_server_init_async(&state->ipc_server_data, + state->path_ipc.buf, &ipc_opts, + handle_client, state)) return error_errno( _("could not start IPC thread pool on '%s'"), state->path_ipc.buf); |
