All of lore.kernel.org
 help / color / mirror / Atom feed
* [LTP] [RESEND][PATCH v2] android: pty01: Fix pty01 test for Android.
@ 2017-09-05 23:03 Sandeep Patil
  2017-09-08  9:07 ` Cyril Hrubis
  0 siblings, 1 reply; 2+ messages in thread
From: Sandeep Patil @ 2017-09-05 23:03 UTC (permalink / raw)
  To: ltp

The test fails because 'grantpt()' is a no-op in bionic and doesn't set
the /dev/pts/X mode to '020600' as expected by the test. The change
skips that check if __BIONIC__ is defined so the rest of the test(s)
can proceed and detect other failures if any.

Signed-off-by: Sandeep Patil <sspatil@google.com>
Acked-by: Petr Vorel <pvorel@suse.cz>
---
v1->v2
------
- Change the check from __ANDROID__ to __BIONIC__
- Added "Acked-by" from pvorel@suse.cz

 testcases/kernel/pty/pty01.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/testcases/kernel/pty/pty01.c b/testcases/kernel/pty/pty01.c
index cbcc65c97..283612d55 100644
--- a/testcases/kernel/pty/pty01.c
+++ b/testcases/kernel/pty/pty01.c
@@ -99,9 +99,12 @@ static int test1(void)
 		tst_brkm(TBROK, NULL, "uid mismatch");
 	}
 
+	 /* grantpt() is a no-op in bionic. */
+#ifndef __BIONIC__
 	if (st.st_mode != (S_IFCHR | S_IRUSR | S_IWUSR | S_IWGRP)) {
 		tst_brkm(TBROK, NULL, "mode mismatch (mode=%o)", st.st_mode);
 	}
+#endif
 
 	slavefd = open(slavename, O_RDWR);
 	if (slavefd >= 0) {
-- 
2.14.1.581.gf28d330327-goog


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [LTP] [RESEND][PATCH v2] android: pty01: Fix pty01 test for Android.
  2017-09-05 23:03 [LTP] [RESEND][PATCH v2] android: pty01: Fix pty01 test for Android Sandeep Patil
@ 2017-09-08  9:07 ` Cyril Hrubis
  0 siblings, 0 replies; 2+ messages in thread
From: Cyril Hrubis @ 2017-09-08  9:07 UTC (permalink / raw)
  To: ltp

Hi!
Pushed, thanks.

-- 
Cyril Hrubis
chrubis@suse.cz

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-09-08  9:07 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-05 23:03 [LTP] [RESEND][PATCH v2] android: pty01: Fix pty01 test for Android Sandeep Patil
2017-09-08  9:07 ` Cyril Hrubis

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.