[Python-checkins] cpython: Issue #20306: Android is the only system that returns NULL for the pw_passwd
stefan.krah
python-checkins at python.org
Tue Apr 26 05:43:33 EDT 2016
https://hg.python.org/cpython/rev/f0f519aca558
changeset: 101154:f0f519aca558
user: Stefan Krah <skrah at bytereef.org>
date: Tue Apr 26 11:43:21 2016 +0200
summary:
Issue #20306: Android is the only system that returns NULL for the pw_passwd
field. Rather than cluttering the tests, translate the arguably more correct
"None" to an empty string.
files:
Modules/pwdmodule.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Modules/pwdmodule.c b/Modules/pwdmodule.c
--- a/Modules/pwdmodule.c
+++ b/Modules/pwdmodule.c
@@ -75,7 +75,7 @@
#define SETS(i,val) sets(v, i, val)
SETS(setIndex++, p->pw_name);
-#if defined(HAVE_STRUCT_PASSWD_PW_PASSWD)
+#if defined(HAVE_STRUCT_PASSWD_PW_PASSWD) && !defined(__ANDROID__)
SETS(setIndex++, p->pw_passwd);
#else
SETS(setIndex++, "");
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list