]> granicus.if.org Git - python/commitdiff
- The pwd module incorrectly advertised its struct type as
authorGuido van Rossum <guido@python.org>
Thu, 23 Oct 2003 23:54:57 +0000 (23:54 +0000)
committerGuido van Rossum <guido@python.org>
Thu, 23 Oct 2003 23:54:57 +0000 (23:54 +0000)
  struct_pwent; this has been renamed to struct_passwd.  (The old name
  is still supported for backwards compatibility.)

Misc/NEWS
Modules/pwdmodule.c

index 203972d5108b57490172031d16234ee7e40616f3..a53fdaf5a482e5f39b55724e6477b62d7854a487 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -47,6 +47,10 @@ Core and builtins
 Extension modules
 -----------------
 
+- The pwd module incorrectly advertised its struct type as
+  struct_pwent; this has been renamed to struct_passwd.  (The old name
+  is still supported for backwards compatibility.)
+
 - The xml.parsers.expat module now provides Expat 1.95.7.
 
 - socket.IPPROTO_IPV6 was added.
index 7e3c3ae170ae88e212aab1d1a0f7e900cd9d8fb3..6bbea33c38df607cbb2fad1606bdb68888e7e6a7 100644 (file)
@@ -184,5 +184,7 @@ initpwd(void)
 
        PyStructSequence_InitType(&StructPwdType, &struct_pwd_type_desc);
        Py_INCREF((PyObject *) &StructPwdType);
+       PyModule_AddObject(m, "struct_passwd", (PyObject *) &StructPwdType);
+       /* And for b/w compatibility (this was defined by mistake): */
        PyModule_AddObject(m, "struct_pwent", (PyObject *) &StructPwdType);
 }