[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240429234610.191144-1-edliaw@google.com>
Date: Mon, 29 Apr 2024 23:46:09 +0000
From: Edward Liaw <edliaw@...gle.com>
To: linux-kernel@...r.kernel.org, Shuah Khan <shuah@...nel.org>,
"Eric W. Biederman" <ebiederm@...ssion.com>, Cyrill Gorcunov <gorcunov@...nvz.org>,
Andrew Morton <akpm@...ux-foundation.org>
Cc: linux-kselftest@...r.kernel.org, kernel-team@...roid.com,
Edward Liaw <edliaw@...gle.com>
Subject: [PATCH] selftests/kcmp: Remove unused open mode
Android bionic warns that open modes are ignored if O_CREAT or O_TMPFILE
aren't specified. The permissions for the file are set above:
fd1 = open(kpath, O_RDWR | O_CREAT | O_TRUNC, 0644);
Fixes: d97b46a64674 ("syscalls, x86: add __NR_kcmp syscall")
Signed-off-by: Edward Liaw <edliaw@...gle.com>
---
tools/testing/selftests/kcmp/kcmp_test.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/testing/selftests/kcmp/kcmp_test.c b/tools/testing/selftests/kcmp/kcmp_test.c
index 25110c7c0b3e..d7a8e321bb16 100644
--- a/tools/testing/selftests/kcmp/kcmp_test.c
+++ b/tools/testing/selftests/kcmp/kcmp_test.c
@@ -91,7 +91,7 @@ int main(int argc, char **argv)
ksft_print_header();
ksft_set_plan(3);
- fd2 = open(kpath, O_RDWR, 0644);
+ fd2 = open(kpath, O_RDWR);
if (fd2 < 0) {
perror("Can't open file");
ksft_exit_fail();
--
2.44.0.769.g3c40516874-goog
Powered by blists - more mailing lists