Issue 2111: mmap segfaults when trying to write a block opened with PROT_READ (original) (raw)

Issue2111

Created on 2008-02-14 14:40 by therve, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
mmap.diff therve,2008-02-14 14:40
Messages (3)
msg62390 - (view) Author: Thomas Herve (therve) * Date: 2008-02-14 14:40
Basically, the write method of mmap objects check the state with is_writable, which check the writability with the access attributes. But the mmap object can be opened correctly specifying the rights with prot=mmap.PROt_READ. Attached patch corrects the problem by setting access to ACCESS_READ with prot is set to PROT_READ, with a test.
msg62424 - (view) Author: Christian Heimes (christian.heimes) * (Python committer) Date: 2008-02-15 08:21
Fixed in r60830 (trunk) Martin, is the fix a candidate for 2.5.3, too?
msg67242 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2008-05-23 14:31
Committed to 2.5 as r63561
History
Date User Action Args
2022-04-11 14:56:30 admin set github: 46365
2008-05-23 14:31:51 loewis set status: pending -> closedmessages: +
2008-02-15 08:21:03 christian.heimes set status: open -> pendingversions: + Python 2.5, - Python 2.6nosy: + loewis, christian.heimesmessages: + priority: highassignee: loewisresolution: accepted
2008-02-14 14:40:03 therve create