Commit bd1c863
BUG: Fix missing check for PyErr_Occurred() in _pyarray_correlate. (#28898)
When running the scipy 1.15 test suite test
signal/tests/test_signaltools.py::test_lfilter_bad_object, with Python
built in debug mode, we see the following error:
```
Fatal Python error: _Py_CheckSlotResult: Slot * of type float succeeded with an exception set
```
`None` ends up as the first argument to `dot`, and this triggers an
error from PyFloat_Multiply. Once an error has occurred, we must avoid
calling multiply again, since it asserts that PyErr_Occurred() is false
if the output is a non-error, which will fail if an error was set at
entry.1 parent 9e50659 commit bd1c863
1 file changed
Lines changed: 8 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1215 | 1215 | | |
1216 | 1216 | | |
1217 | 1217 | | |
| 1218 | + | |
1218 | 1219 | | |
1219 | 1220 | | |
1220 | 1221 | | |
| |||
1225 | 1226 | | |
1226 | 1227 | | |
1227 | 1228 | | |
| 1229 | + | |
| 1230 | + | |
| 1231 | + | |
1228 | 1232 | | |
1229 | 1233 | | |
1230 | 1234 | | |
| |||
1236 | 1240 | | |
1237 | 1241 | | |
1238 | 1242 | | |
1239 | | - | |
| 1243 | + | |
| 1244 | + | |
1240 | 1245 | | |
1241 | 1246 | | |
1242 | 1247 | | |
1243 | 1248 | | |
1244 | 1249 | | |
1245 | | - | |
| 1250 | + | |
1246 | 1251 | | |
1247 | 1252 | | |
1248 | 1253 | | |
1249 | 1254 | | |
1250 | 1255 | | |
1251 | 1256 | | |
| 1257 | + | |
1252 | 1258 | | |
1253 | 1259 | | |
1254 | 1260 | | |
| |||
0 commit comments