[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20211213095743.3630-1-caoyixuan2019@email.szu.edu.cn>
Date: Mon, 13 Dec 2021 17:57:43 +0800
From: Yixuan Cao <caoyixuan2019@...il.szu.edu.cn>
To: akpm@...ux-foundation.org
Cc: broonie@...nel.org, seanga2@...il.com, weizhenliang@...wei.com,
tangbin@...s.chinamobile.com, zhaochongxi2019@...il.szu.edu.cn,
zhangyinan2019@...il.szu.edu.cn, linux-kernel@...r.kernel.org,
Yixuan Cao <caoyixuan2019@...il.szu.edu.cn>
Subject: [PATCH] tools/vm/page_owner_sort.c: delete invalid duplicate code
I noticed that there is two invalid lines of duplicate code.
It's better to delete it.
Signed-off-by: Yixuan Cao <caoyixuan2019@...il.szu.edu.cn>
---
tools/vm/page_owner_sort.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/tools/vm/page_owner_sort.c b/tools/vm/page_owner_sort.c
index c9fedc1806d5..e76addb2bfe7 100644
--- a/tools/vm/page_owner_sort.c
+++ b/tools/vm/page_owner_sort.c
@@ -229,8 +229,6 @@ static void add_list(char *buf, int len)
list[list_size].pid = get_pid(buf);
list[list_size].ts_nsec = get_ts_nsec(buf);
list[list_size].free_ts_nsec = get_free_ts_nsec(buf);
- memcpy(list[list_size].txt, buf, len);
- list[list_size].txt[len] = 0;
list_size++;
if (list_size % 1000 == 0) {
printf("loaded %d\r", list_size);
--
2.31.1
Powered by blists - more mailing lists