Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRené Scharfe <l.s.r@web.de>2022-10-30 14:52:40 +0300
committerTaylor Blau <me@ttaylorr.com>2022-10-30 21:04:48 +0300
commitd82dbbd849fadd9d61d9489a03b429b6d1413c81 (patch)
tree5363081cc9cfa212facf594778e0ee458cbdc8dc /fsmonitor-ipc.c
parenteb5b6b57d0e9fba0e50871ece4ea79e76cd61a36 (diff)
replace and remove run_command_v_opt_tr2()
The convenience function run_command_v_opt_tr2() is only used by a single caller. Use struct child_process and run_command() directly instead and remove the underused function. Signed-off-by: René Scharfe <l.s.r@web.de> Signed-off-by: Taylor Blau <me@ttaylorr.com>
Diffstat (limited to 'fsmonitor-ipc.c')
-rw-r--r--fsmonitor-ipc.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/fsmonitor-ipc.c b/fsmonitor-ipc.c
index c0f42301c8..19d772f0f3 100644
--- a/fsmonitor-ipc.c
+++ b/fsmonitor-ipc.c
@@ -54,10 +54,14 @@ enum ipc_active_state fsmonitor_ipc__get_state(void)
static int spawn_daemon(void)
{
- const char *args[] = { "fsmonitor--daemon", "start", NULL };
+ struct child_process cmd = CHILD_PROCESS_INIT;
- return run_command_v_opt_tr2(args, RUN_COMMAND_NO_STDIN | RUN_GIT_CMD,
- "fsmonitor");
+ cmd.git_cmd = 1;
+ cmd.no_stdin = 1;
+ cmd.trace2_child_class = "fsmonitor";
+ strvec_pushl(&cmd.args, "fsmonitor--daemon", "start", NULL);
+
+ return run_command(&cmd);
}
int fsmonitor_ipc__send_query(const char *since_token,