Issue 4583: segfault when mutating memoryview to array.array when array is resized (original) (raw)

Created on 2008-12-07 21:30 by gumpy, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
arraybuf.patch pitrou,2008-12-13 20:58
arraybuf2.patch pitrou,2008-12-16 21:27
Messages (4)
msg77260 - (view) Author: (gumpy) Date: 2008-12-07 21:30
This is with r67651 and related to #4569, #4509 and possibly #4580. >>> from array import array >>> a = array('i', range(16)) >>> m = memoryview(a) >>> a.extend(array('i', range(48))) >>> m[:] = array('i', range(64)) Segmentation fault >>> from array import array >>> a = array('b', range(16)) >>> m = memoryview(a) >>> a.extend(array('b', range(48))) >>> m[:] = array('b', range(64)) Segmentation fault
msg77763 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2008-12-13 20:58
Here is a patch for the array module.
msg77934 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2008-12-16 21:27
Nothing new in this patch except that it fixes the bogus indentation of the previous patch.
msg78032 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2008-12-18 17:11
Fixed in r67840. No need to backport to 2.x since the array object there doesn't support the new buffer protocol.
History
Date User Action Args
2022-04-11 14:56:42 admin set github: 48833
2008-12-18 17:11:12 pitrou set status: open -> closedresolution: fixedmessages: +
2008-12-16 21:32:28 pitrou set nosy: + teoliphant
2008-12-16 21:27:22 pitrou set files: + arraybuf2.patchmessages: +
2008-12-13 20:58:40 pitrou set files: + arraybuf.patchnosy: + pitroumessages: + priority: criticalkeywords: + patch, needs reviewstage: patch review
2008-12-07 21:30:16 gumpy create