[New-bugs-announce] [issue12562] calling mmap twice fails on Windows

Piotr Zolnierczuk report at bugs.python.org
Thu Jul 14 20:00:02 CEST 2011


New submission from Piotr Zolnierczuk <piotr.zolnierczuk at gmail.com>:

Hi,
I am trying to migrate from Python 2.5 to Python 2.7 I found though the mmap behaves differently on Windows XP between the two versions. It boils down to the following code:
import mmap
map1 = mmap.mmap(fileno=0, tagname='MyData', length=4096)
map2 = mmap.mmap(fileno=0, tagname='MyData', length=8192)

It runs fine (so I can "resize" shared memory) on XP with 2.5.4, but when running on 2.7.2 I get the following error

Traceback (most recent call last):
  File "D:\Workspace\memmap_test.py", line 3, in <module>
    map2 = mmap.mmap(fileno=0, tagname='MyData', length=8192)
WindowsError: [Error 5] Access is denied

----------
messages: 140349
nosy: zolnie
priority: normal
severity: normal
status: open
title: calling mmap twice fails on Windows
versions: Python 2.7

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue12562>
_______________________________________


More information about the New-bugs-announce mailing list