summaryrefslogtreecommitdiff
path: root/numpy/f2py/tests/test_compile_function.py
diff options
context:
space:
mode:
authorEric Wieser <wieser.eric@gmail.com>2018-06-04 23:23:33 -0700
committerEric Wieser <wieser.eric@gmail.com>2018-06-07 09:47:20 -0700
commita0b2f3a5ee665ba68235c9f8e9503b294748b8e1 (patch)
tree0b5fe63aee38fc9991378223c34bffe97d3327b0 /numpy/f2py/tests/test_compile_function.py
parent5064f4a025bbf795017e1d7db6b5c080b10823dd (diff)
downloadnumpy-a0b2f3a5ee665ba68235c9f8e9503b294748b8e1.tar.gz
BUG: Set ndarray.base before calling __array_finalize__
Fixes #11237 Without this, we expose arrays to python before the lifetime of their buffer has been correctly attached, which can lead to use-after-frees (see the referenced issue). Unfortunately, this means that `PyArray_SetBaseObject(arr, base)` is still broken in downstream code for any cases where `arr.__array_finalize__ is not None`. We may have no choice but to deprecate this function, and expose PyArray_FromDescrAndBase. But lets leave fixing public API to a later date...
Diffstat (limited to 'numpy/f2py/tests/test_compile_function.py')
0 files changed, 0 insertions, 0 deletions