Details
Description
Python segfaults when connecting to a signal attribute of a temporary object; e.g.
tv = QTreeView()
...
tv.selectionModel().destroyed.connect(callback)
What happens is a PyObject* is created for the selection model, but is destroyed after its 'destroyed' attribute is gotten and before the .connect(callback) call.
It may not segfault in a non-debug python build because the recently freed memory may still contain its old values
Attachments
Issue Links
- is duplicated by
-
PYSIDE-161 Crash on connect to currentRowChanged slot
- Closed
- relates to
-
PYSIDE-2201 Segfault when calling signal of temporary
- Closed
- resulted in
-
PYSIDE-1057 QNetworkReply leak
- Open
For Gerrit Dashboard: PYSIDE-79 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
175188,8 | Fix Segfault when using connect | dev | pyside/pyside-setup | Status: ABANDONED | -1 | 0 |
175705,3 | Set the minimum Python3 to 3.3 | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
176374,22 | Fix Segfault when using connect (w/o instrumentation) | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
178656,1 | Fix Segfault when using connect (w/o instrumentation) | dev | pyside/pyside-setup | Status: ABANDONED | 0 | 0 |
178718,2 | Fix Segfault when using connect | dev | pyside/pyside-setup | Status: ABANDONED | 0 | 0 |
178886,1 | Fix Segfault when using connect | dev | pyside/pyside-setup | Status: ABANDONED | 0 | 0 |
178917,3 | Fix build on Winsdows | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
182483,2 | Fix “Fix Segfault when using connect” | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
329465,2 | PySide: write a renamer script for debugging | 6.0 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
329471,6 | PySide: write a renamer script for debugging | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
329566,2 | PySide: write a renamer script for debugging | 5.15 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
332188,2 | PySide: write a renamer script for debugging, improved | 6.0 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
332189,2 | PySide: write a renamer script for debugging, improved | 5.15 | pyside/pyside-setup | Status: ABANDONED | +2 | 0 |
332230,2 | PySide: write a renamer script for debugging, improved | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
332231,3 | feature: Supply switching for newly created objects | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
332382,2 | feature: Supply switching for newly created objects | 6.0 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
354381,3 | Update blacklist.txt for errors in debug mode | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
354834,2 | Update blacklist.txt for errors in debug mode | 6.1 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
456357,7 | signals: Introduce Weak Reference to protect lost SignalInstance | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
457731,16 | signal: Finally clean up all leaks after complete understanding | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
457976,2 | signals: Introduce Weak Reference to protect lost SignalInstance | 6.4 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
461637,2 | signal: Finally clean up all leaks after complete understanding | 6.4 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
464937,2 | SignalInstance: Fix another very old bug | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
464946,2 | SignalInstance: Fix another very old bug | 6.4 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
465293,2 | SignalInstance: Fix more very old errors due to unlucky exposure | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
465633,2 | SignalInstance: Fix more very old errors due to unlucky exposure | 6.4 | pyside/pyside-setup | Status: MERGED | +2 | 0 |