aboutsummaryrefslogtreecommitdiff
path: root/meta-linaro-integration/recipes-overlayed/ltp/ltp/make-setregid02-work.patch
blob: 4836010bdf85414bb7590877b01afd53fb27306c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
[PATCH] make setregid02 work

Upstream-Status: Inappropriate [configuration]

there is no "nobody" group in oe-core, the user "nobody" belongs to
"nogroup" group, so replace nobody with nogroup to make the test pass

Signed-off-by: Roy.Li <rongqing.li@windriver.com>
---
 testcases/kernel/syscalls/setregid/setregid02.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/testcases/kernel/syscalls/setregid/setregid02.c b/testcases/kernel/syscalls/setregid/setregid02.c
index 8058627..866bee4 100644
--- a/testcases/kernel/syscalls/setregid/setregid02.c
+++ b/testcases/kernel/syscalls/setregid/setregid02.c
@@ -41,7 +41,7 @@ static gid_t neg_one = -1;
 
 static struct passwd *ltpuser;
 
-static struct group nobody, root, bin;
+static struct group nogroup, root, bin;
 
 /*
  * The following structure contains all test data.  Each structure in the array
@@ -57,17 +57,17 @@ struct test_data_t {
 	char *test_msg;
 } test_data[] = {
 	{
-	&neg_one, &root.gr_gid, EPERM, &nobody, &nobody,
+	&neg_one, &root.gr_gid, EPERM, &nogroup, &nogroup,
 		    "After setregid(-1, root),"}, {
-	&neg_one, &bin.gr_gid, EPERM, &nobody, &nobody,
+	&neg_one, &bin.gr_gid, EPERM, &nogroup, &nogroup,
 		    "After setregid(-1, bin)"}, {
-	&root.gr_gid, &neg_one, EPERM, &nobody, &nobody,
+	&root.gr_gid, &neg_one, EPERM, &nogroup, &nogroup,
 		    "After setregid(root,-1),"}, {
-	&bin.gr_gid, &neg_one, EPERM, &nobody, &nobody,
+	&bin.gr_gid, &neg_one, EPERM, &nogroup, &nogroup,
 		    "After setregid(bin, -1),"}, {
-	&root.gr_gid, &bin.gr_gid, EPERM, &nobody, &nobody,
+	&root.gr_gid, &bin.gr_gid, EPERM, &nogroup, &nogroup,
 		    "After setregid(root, bin)"}, {
-	&bin.gr_gid, &root.gr_gid, EPERM, &nobody, &nobody,
+	&bin.gr_gid, &root.gr_gid, EPERM, &nogroup, &nogroup,
 		    "After setregid(bin, root),"}
 };
 
@@ -165,7 +165,7 @@ static void setup(void)
 } while (0)
 
 	GET_GID(root);
-	GET_GID(nobody);
+	GET_GID(nogroup);
 	GET_GID(bin);
 
 	TEST_PAUSE;
-- 
1.9.1