mirror of
https://github.com/python/cpython.git
synced 2025-10-17 20:28:43 +00:00
SF bug 128713: type(mmap_object) blew up on Linux.
This commit is contained in:
parent
b9e202b2dc
commit
2caf8df868
4 changed files with 16 additions and 5 deletions
|
@ -841,9 +841,6 @@ new_mmap_object(PyObject *self, PyObject *args)
|
|||
int fileno;
|
||||
HANDLE fh = 0;
|
||||
|
||||
/* Patch the object type */
|
||||
mmap_object_type.ob_type = &PyType_Type;
|
||||
|
||||
if (!PyArg_ParseTuple(args,
|
||||
"iO|z",
|
||||
&fileno,
|
||||
|
@ -956,6 +953,10 @@ DL_EXPORT(void)
|
|||
initmmap(void)
|
||||
{
|
||||
PyObject *dict, *module;
|
||||
|
||||
/* Patch the object type */
|
||||
mmap_object_type.ob_type = &PyType_Type;
|
||||
|
||||
module = Py_InitModule ("mmap", mmap_functions);
|
||||
dict = PyModule_GetDict (module);
|
||||
mmap_module_error = PyExc_EnvironmentError;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue