Bug #1344508, Fix UNIX mmap leaking file descriptors. Will backport.
This commit is contained in:
parent
245a5ab31b
commit
7b631793ab
|
@ -177,6 +177,8 @@ Core and builtins
|
|||
Extension Modules
|
||||
-----------------
|
||||
|
||||
- Bug #1344508, Fix UNIX mmap leaking file descriptors
|
||||
|
||||
- Patch #1338314, Bug #1336623: fix tarfile so it can extract
|
||||
REGTYPE directories from tarfiles written by old programs.
|
||||
|
||||
|
|
|
@ -99,6 +99,7 @@ mmap_object_dealloc(mmap_object *m_obj)
|
|||
#endif /* MS_WINDOWS */
|
||||
|
||||
#ifdef UNIX
|
||||
close(m_obj->fd);
|
||||
if (m_obj->data!=NULL) {
|
||||
msync(m_obj->data, m_obj->size, MS_SYNC);
|
||||
munmap(m_obj->data, m_obj->size);
|
||||
|
|
Loading…
Reference in New Issue