Skip to contentSkip to conversation

ltp: fix typo in testcases/kernel/syscalls/chown/chown03.c

PATCH In review Wei Yongjun 2 participants 2 messages May 27, 2009

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ltp: fix typo in testcases/kernel/syscalls/chown/chown03.c

Fix typo in testcases/kernel/syscalls/chown/chown03.c, which use ltpuser->pw_uid in call to setegid() should be ltpuser->pw_gid.

---
 testcases/kernel/syscalls/chown/chown03.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
testcases/kernel/syscalls/chown/chown03.c +2 -2
index fde107a..f27cb6f 100644
@@ -213,9 +213,9 @@ void setup()
 	}
 
 	ltpuser = getpwnam(nobody_uid);
-	if (setegid(ltpuser->pw_uid) == -1) {
+	if (setegid(ltpuser->pw_gid) == -1) {
 		tst_resm(TINFO, "setegid failed to "
-			 "to set the effective uid to %d", ltpuser->pw_uid);
+			 "to set the effective uid to %d", ltpuser->pw_gid);
 		perror("setegid");
 	}
 	if (seteuid(ltpuser->pw_uid) == -1) {
Signature · 15 lines
1.6.0.2.530.g67faa




------------------------------------------------------------------------------
Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT 
is a gathering of tech-side developers & brand creativity professionals. Meet
the minds behind Google Creative Lab, Visual Complexity, Processing, & 
iPhoneDevCamp as they present alongside digital heavyweights like Barbarian 
Group, R/GA, & Big Spaceship. http://p.sf.net/sfu/creativitycat-com 
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list
#1 lore raw
Quoted 5 lines · Wei Yongjun

Fix typo in testcases/kernel/syscalls/chown/chown03.c, which use ltpuser->pw_uid in call to setegid() should be ltpuser->pw_gid.

Thanks.

Regards--
Subrata

Quoted 10 lines
---
 testcases/kernel/syscalls/chown/chown03.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
testcases/kernel/syscalls/chown/chown03.c +0 -0
index fde107a..f27cb6f 100644
@@ -213,9 +213,9 @@ void setup()
 	}

testcases/kernel/syscalls/chown/chown03.c void setup() · line 221

Quoted 10 lines
testcases/kernel/syscalls/chown/chown03.c +2 -2
 
 	ltpuser = getpwnam(nobody_uid);
-	if (setegid(ltpuser->pw_uid) == -1) {
+	if (setegid(ltpuser->pw_gid) == -1) {
 		tst_resm(TINFO, "setegid failed to "
-			 "to set the effective uid to %d", ltpuser->pw_uid);
+			 "to set the effective uid to %d", ltpuser->pw_gid);
 		perror("setegid");
 	}
 	if (seteuid(ltpuser->pw_uid) == -1) {

------------------------------------------------------------------------------
Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT is a gathering of tech-side developers & brand creativity professionals. Meet the minds behind Google Creative Lab, Visual Complexity, Processing, & iPhoneDevCamp as they present alongside digital heavyweights like Barbarian Group, R/GA, & Big Spaceship. http://p.sf.net/sfu/creativitycat-com
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list