diff -r 6dbc4d6ff31e Doc/library/spwd.rst --- a/Doc/library/spwd.rst Tue Aug 06 16:03:33 2013 +0200 +++ b/Doc/library/spwd.rst Wed Aug 07 22:45:47 2013 +0800 @@ -19,9 +19,9 @@ +-------+---------------+---------------------------------+ | Index | Attribute | Meaning | +=======+===============+=================================+ -| 0 | ``sp_nam`` | Login name | +| 0 | ``sp_namp`` | Login name | +-------+---------------+---------------------------------+ -| 1 | ``sp_pwd`` | Encrypted password | +| 1 | ``sp_pwdp`` | Encrypted password | +-------+---------------+---------------------------------+ | 2 | ``sp_lstchg`` | Date of last change | +-------+---------------+---------------------------------+ @@ -36,15 +36,15 @@ +-------+---------------+---------------------------------+ | 6 | ``sp_inact`` | Number of days after password | | | | expires until account is | -| | | blocked | +| | | disabled | +-------+---------------+---------------------------------+ | 7 | ``sp_expire`` | Number of days since 1970-01-01 | -| | | until account is disabled | +| | | when account expires | +-------+---------------+---------------------------------+ | 8 | ``sp_flag`` | Reserved | +-------+---------------+---------------------------------+ -The sp_nam and sp_pwd items are strings, all others are integers. +The sp_namp and sp_pwdp items are strings, all others are integers. :exc:`KeyError` is raised if the entry asked for cannot be found. The following functions are defined: diff -r 6dbc4d6ff31e Modules/spwdmodule.c --- a/Modules/spwdmodule.c Tue Aug 06 16:03:33 2013 +0200 +++ b/Modules/spwdmodule.c Wed Aug 07 22:45:47 2013 +0800 @@ -26,14 +26,14 @@ #if defined(HAVE_GETSPNAM) || defined(HAVE_GETSPENT) static PyStructSequence_Field struct_spwd_type_fields[] = { - {"sp_nam", "login name"}, - {"sp_pwd", "encrypted password"}, + {"sp_namp", "login name"}, + {"sp_pwdp", "encrypted password"}, {"sp_lstchg", "date of last change"}, {"sp_min", "min #days between changes"}, {"sp_max", "max #days between changes"}, {"sp_warn", "#days before pw expires to warn user about it"}, - {"sp_inact", "#days after pw expires until account is blocked"}, - {"sp_expire", "#days since 1970-01-01 until account is disabled"}, + {"sp_inact", "#days after pw expires until account is disabled"}, + {"sp_expire", "#days since 1970-01-01 when account expires"}, {"sp_flag", "reserved"}, {0} }; @@ -41,7 +41,7 @@ PyDoc_STRVAR(struct_spwd__doc__, "spwd.struct_spwd: Results from getsp*() routines.\n\n\ This object may be accessed either as a 9-tuple of\n\ - (sp_nam,sp_pwd,sp_lstchg,sp_min,sp_max,sp_warn,sp_inact,sp_expire,sp_flag)\n\ + (sp_namp,sp_pwdp,sp_lstchg,sp_min,sp_max,sp_warn,sp_inact,sp_expire,sp_flag)\n\ or via the object attributes as named in the above tuple."); static PyStructSequence_Desc struct_spwd_type_desc = {