diff options
Diffstat (limited to 'meta/recipes-extended/ltp/ltp/setregid01-security-string-formatting.patch')
-rw-r--r-- | meta/recipes-extended/ltp/ltp/setregid01-security-string-formatting.patch | 46 |
1 files changed, 0 insertions, 46 deletions
diff --git a/meta/recipes-extended/ltp/ltp/setregid01-security-string-formatting.patch b/meta/recipes-extended/ltp/ltp/setregid01-security-string-formatting.patch deleted file mode 100644 index 24449148f2..0000000000 --- a/meta/recipes-extended/ltp/ltp/setregid01-security-string-formatting.patch +++ /dev/null | |||
@@ -1,46 +0,0 @@ | |||
1 | From 430e05c2169ed15aaa6d7f9459edd607603cee02 Mon Sep 17 00:00:00 2001 | ||
2 | From: =?UTF-8?q?Daniel=20D=C3=ADaz?= <daniel.diaz@linaro.org> | ||
3 | Date: Mon, 25 Feb 2019 10:44:33 -0600 | ||
4 | Subject: [PATCH] setregid01: Fix security warning for string formatting | ||
5 | MIME-Version: 1.0 | ||
6 | Content-Type: text/plain; charset=UTF-8 | ||
7 | Content-Transfer-Encoding: 8bit | ||
8 | |||
9 | GCC 8.2.0 complains with the following: | ||
10 | setregid01.c: In function 'run': | ||
11 | setregid01.c:47:3: error: format not a string literal and no format arguments [-Werror=format-security] | ||
12 | tst_res(TFAIL | TTERRNO, tc->msg); | ||
13 | ^~~~~~~ | ||
14 | because there is no string formatting in the message. This can | ||
15 | be seen with CFLAGS set to: | ||
16 | -Wformat -Wformat-security -Werror=format-security | ||
17 | as Yocto Project's Poky does, e.g.: | ||
18 | http://errors.yoctoproject.org/Errors/Details/230043/ | ||
19 | |||
20 | Upstream-Status: Backport [46e1eda55f188810e6bf3a939b92d604321807ae] | ||
21 | |||
22 | Signed-off-by: Daniel Díaz <daniel.diaz@linaro.org> | ||
23 | Reviewed-by: Enji Cooper <yaneurabeya@gmail.com> | ||
24 | --- | ||
25 | testcases/kernel/syscalls/setregid/setregid01.c | 4 ++-- | ||
26 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
27 | |||
28 | diff --git a/testcases/kernel/syscalls/setregid/setregid01.c b/testcases/kernel/syscalls/setregid/setregid01.c | ||
29 | index f2e41e134..8c9e11918 100644 | ||
30 | --- a/testcases/kernel/syscalls/setregid/setregid01.c | ||
31 | +++ b/testcases/kernel/syscalls/setregid/setregid01.c | ||
32 | @@ -44,9 +44,9 @@ static void run(unsigned int n) | ||
33 | TEST(SETREGID(*tc->arg1, *tc->arg2)); | ||
34 | |||
35 | if (TST_RET == -1) | ||
36 | - tst_res(TFAIL | TTERRNO, tc->msg); | ||
37 | + tst_res(TFAIL | TTERRNO, "%s", tc->msg); | ||
38 | else | ||
39 | - tst_res(TPASS, tc->msg); | ||
40 | + tst_res(TPASS, "%s", tc->msg); | ||
41 | } | ||
42 | |||
43 | static void setup(void) | ||
44 | -- | ||
45 | 2.17.1 | ||
46 | |||