[issue37188] Creating a ctypes array of an element with size zero causes "Fatal Python error: Floating point exception"
Eric Wieser
report at bugs.python.org
Fri Jun 7 02:41:34 EDT 2019
New submission from Eric Wieser <wieser.eric at gmail.com>:
Introduced in the fix to bpo-36504, GH-12660.
```python
>>> (ctypes.c_uint8 * 0 * 2)()
Fatal Python error: Floating point exception
>>> struct Empty(ctypes.Structure): _fields_ = []
>>> (Empty * 2)()
Fatal Python error: Floating point exception
```
This used to work just fine
----------
messages: 344901
nosy: Eric Wieser, ZackerySpytz
priority: normal
severity: normal
status: open
title: Creating a ctypes array of an element with size zero causes "Fatal Python error: Floating point exception"
type: crash
versions: Python 2.7, Python 3.7, Python 3.8
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue37188>
_______________________________________
More information about the Python-bugs-list
mailing list