Skip to content

Commit

Permalink
SSSCTL: Use wrapper function for analyze
Browse files Browse the repository at this point in the history
Reviewed-by: Iker Pedrosa <[email protected]>
Reviewed-by: Sumit Bose <[email protected]>
  • Loading branch information
justin-stephenson authored and pbrezina committed Nov 1, 2022
1 parent 6d87af5 commit ee0d73a
Showing 1 changed file with 1 addition and 13 deletions.
14 changes: 1 addition & 13 deletions src/tools/sssctl/sssctl_logs.c
Original file line number Diff line number Diff line change
Expand Up @@ -602,19 +602,7 @@ errno_t sssctl_analyze(struct sss_cmdline *cmdline,
#endif
errno_t ret;

const char **args = talloc_array_size(tool_ctx,
sizeof(char *),
cmdline->argc + 2);
if (!args) {
return ENOMEM;
}
memcpy(&args[1], cmdline->argv, sizeof(char *) * cmdline->argc);
args[0] = SSS_ANALYZE;
args[cmdline->argc + 1] = NULL;

ret = sssctl_run_command(args);

talloc_free(args);
ret = sssctl_wrap_command(SSS_ANALYZE, cmdline, tool_ctx, pvt);

return ret;
}

0 comments on commit ee0d73a

Please sign in to comment.