PySide Bugzilla Closed for New Bugs

PySide is now a Qt Add-on and uses the Qt Project's JIRA Bug Tracker instead of this Bugzilla instance. This Bugzilla is left for reference purposes.

Bug 1158 - segfault in QGridLayout.takeAt ( -1 )
: segfault in QGridLayout.takeAt ( -1 )
Status: UNCONFIRMED
Product: PySide
Classification: Unclassified
Component: QtGui
: 1.1.0
: PC Linux
: P5 minor
Assigned To: Hugo Parente Lima
:
:
:
  Show dependency treegraph
 
Reported: 2012-02-29 22:36 EET by Nik A. Melchior
Modified: 2012-03-08 16:58 EET (History)
8 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nik A. Melchior 2012-02-29 22:36:53 EET
Here is a simple test program to reproduce the crash:

{{{
import sys
from PySide.QtGui import *

app = QApplication ( sys.argv )
window = QFrame()
layout = QGridLayout ( window )
widget = layout.takeAt ( -1 )
window.show()
sys.exit ( app.exec_() )
}}}

Admittedly, -1 is not a valid index, but other layout classes handle the error
more gracefully.  If QGridLayout is replaced by QVBoxLayout, for example,
takeAt(-1) returns None.

Although it may seem contrived to pass -1 to takeAt(), -1 is returned by
QGridLayout.indexOf() when passed an invalid widget.
Comment 1 Matti Airas 2012-03-08 16:58:02 EET
PySide is now a Qt-addon and uses Qt Project's JIRA tool for tracking bugs.
Please verify that the bug is still valid and re-submit it in the address
below:

https://bugreports.qt-project.org/

Sorry for the inconvenience!