[PATCH] tools: perf: Two typos have been corrected

Lu Hongfei posted 1 patch 2 years, 7 months ago
There is a newer version of this series
tools/perf/builtin-diff.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
[PATCH] tools: perf: Two typos have been corrected
Posted by Lu Hongfei 2 years, 7 months ago
When wrapping code, use ';' better than using ',' which is more
in line with the coding habits of most engineers.

Signed-off-by: Lu Hongfei <luhongfei@vivo.com>
---
 tools/perf/builtin-diff.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tools/perf/builtin-diff.c b/tools/perf/builtin-diff.c
index e8a1b16aa5f8..57d300d8e570 100644
--- a/tools/perf/builtin-diff.c
+++ b/tools/perf/builtin-diff.c
@@ -1915,8 +1915,8 @@ static int data_init(int argc, const char **argv)
 		struct perf_data *data = &d->data;
 
 		data->path  = use_default ? defaults[i] : argv[i];
-		data->mode  = PERF_DATA_MODE_READ,
-		data->force = force,
+		data->mode  = PERF_DATA_MODE_READ;
+		data->force = force;
 
 		d->idx  = i;
 	}
-- 
2.39.0
Re: [PATCH] tools: perf: Two typos have been corrected
Posted by Ian Rogers 2 years, 7 months ago
On Thu, Jul 6, 2023 at 2:46 AM Lu Hongfei <luhongfei@vivo.com> wrote:
>
> When wrapping code, use ';' better than using ',' which is more
> in line with the coding habits of most engineers.
>
> Signed-off-by: Lu Hongfei <luhongfei@vivo.com>

Acked-by: Ian Rogers <irogers@google.com>

Thanks,
Ian

> ---
>  tools/perf/builtin-diff.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/tools/perf/builtin-diff.c b/tools/perf/builtin-diff.c
> index e8a1b16aa5f8..57d300d8e570 100644
> --- a/tools/perf/builtin-diff.c
> +++ b/tools/perf/builtin-diff.c
> @@ -1915,8 +1915,8 @@ static int data_init(int argc, const char **argv)
>                 struct perf_data *data = &d->data;
>
>                 data->path  = use_default ? defaults[i] : argv[i];
> -               data->mode  = PERF_DATA_MODE_READ,
> -               data->force = force,
> +               data->mode  = PERF_DATA_MODE_READ;
> +               data->force = force;
>
>                 d->idx  = i;
>         }
> --
> 2.39.0
>