* [PATCH] common/rc: accept "localdomain" to mean YP/NIS disabled
@ 2017-02-28 22:09 Eric Biggers
0 siblings, 0 replies; only message in thread
From: Eric Biggers @ 2017-02-28 22:09 UTC (permalink / raw)
To: fstests; +Cc: Eric Biggers
From: Eric Biggers <ebiggers@google.com>
When asked to 'cat' the passwd or group files, currently xfstests runs
the 'domainname' program to get what the kernel thinks the domainname
is. It seems that traditionally this has been "(none)" if YP/NIS is not
in use. However, Android devices use a different convention which is to
set the domainname to "localdomain". Therefore, this patch updates
xfstests to accept both conventions to indicate YP/NIS disabled. This
stops a number of tests from failing when run on Android.
Signed-off-by: Eric Biggers <ebiggers@google.com>
---
common/rc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/common/rc b/common/rc
index 8f233346..aa78d4b2 100644
--- a/common/rc
+++ b/common/rc
@@ -1792,7 +1792,7 @@ _yp_active()
{
local dn
dn=$(domainname 2>/dev/null)
- test -n "${dn}" -a "${dn}" != "(none)"
+ test -n "${dn}" -a "${dn}" != "(none)" -a "${dn}" != "localdomain"
echo $?
}
--
2.11.0.483.g087da7b7c-goog
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2017-03-01 2:30 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-02-28 22:09 [PATCH] common/rc: accept "localdomain" to mean YP/NIS disabled Eric Biggers
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox