<br><font size=2 face="sans-serif">I have a similar problem under SIP 3.3/PyQt
3.3/Qt 3.0.4. I haven't solved it, though. I don't know if it's a SIP/PyQt
problem or a Qt problem.</font>
<br>
<br><font size=2 face="sans-serif">I think you will find that the focusData()
list is corrupted or has corrupted objects in it. In your case, looks like
the QWidget destructor is scanning the focusData() list and finding a QWidget
supposedly at address 0xffffffff. No wonder Qt has a problem finding this
object's parent.</font>
<br>
<br><font size=2 face="sans-serif">In my case, I see crashes when using
tab to change the keyboard focus. This leads to a similar scan of focusData(),
and crashes when focusProxy() gets called on a non-existant or corrupted
widget.</font>
<br>
<br><font size=2 face="sans-serif">The corruption must happen sometime
previously, but I don't know when. It seems related to deleting widgets/items
associated with a table. In my case, I'm deleting and recreating the entire
table. As far as I can tell by watching reference counts and using prints
in __del__ methods, the deletions are happening as expected at the python
level. This is supposed to clean up the focusData() list. Somehow either
the cleanup isn't happening or the list/objects are being overwritten in
some other way.</font>
<br>
<br><font size=2 face="sans-serif">That's as far as I've gotten. Hope that
helps.</font>
<br><font size=2 face="sans-serif"><br>
_________________________________<br>
Andy Anderson<br>
MSC.Software Corporation<br>
Andy.Anderson@mscsoftware.com<br>
</font>
<br><font size=2><tt>pykde-admin@mats.imk.fraunhofer.de wrote on 11/11/2003
01:16:08 AM:<br>
<br>
&gt; Ok, in changing selection/focus from one table cell to another, thisis
what I <br>
&gt; got (I'm using sip-3.8/pyqt-3.8.1/qt-3.2.2):<br>
&gt; <br>
&gt; Program received signal SIGSEGV, Segmentation fault.<br>
&gt; [Switching to Thread 16384 (LWP 2947)]<br>
&gt; 0x404cf324 in QObject::parent() const (this=0xffffffff) at qobject.h:154<br>
&gt; 154 &nbsp; &nbsp; qobject.h: No such file or directory.<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; in qobject.h<br>
&gt; (gdb) bt<br>
&gt; #0 &nbsp;0x404cf324 in QObject::parent() const (this=0xffffffff) at
qobject.h:154<br>
&gt; #1 &nbsp;0x404ce0d3 in QWidget::parentWidget(bool) const (this=0xffffffff,
<br>
&gt; sameWindow=false) at qwidget.h:852<br>
&gt; #2 &nbsp;0x405f2c3b in ~QWidget (this=0x8ac60d0) at kernel/qwidget.cpp:895<br>
&gt; #3 &nbsp;0x4068b42f in ~QFrame (this=0x8ac60d0) at .moc/debug-shared-mt/<br>
&gt; moc_qvbox.cpp:28<br>
&gt; #4 &nbsp;0x406a3c67 in ~QLineEdit (this=0x8ac60d0) at widgets/qlineedit.cpp:441<br>
&gt; #5 &nbsp;0x405b40a6 in QObject::event(QEvent*) (this=0x8ac60d0, e=0x8a8c2c8)
at <br>
&gt; kernel/qobject.cpp:750<br>
&gt; #6 &nbsp;0x405f9591 in QWidget::event(QEvent*) (this=0x8ac60d0, e=0x8a8c2c8)
at <br>
&gt; kernel/qwidget.cpp:4408<br>
&gt; #7 &nbsp;0x406a59f2 in QLineEdit::event(QEvent*) (this=0x8ac60d0,
e=0x8a8c2c8) at <br>
&gt; widgets/qlineedit.cpp:1406<br>
&gt; ...<br>
&gt; I'll include the rest below for the interested... It looks like the
parent <br>
&gt; information was somehow invalid? &nbsp;It doesn't look like the destructor
did <br>
&gt; anything that it shouldn't have, but I didn't really trace through
the whole <br>
&gt; thing.<br>
&gt; <br>
&gt; kernel/qwidget.cpp:895:<br>
&gt; <br>
&gt; &nbsp; &nbsp; 886 &nbsp; &nbsp; // Remove myself and all children
from the can-take-focus list<br>
&gt; &nbsp; &nbsp; 887 &nbsp; &nbsp; QFocusData *f = focusData( FALSE );<br>
&gt; &nbsp; &nbsp; 888 &nbsp; &nbsp; if ( f ) {<br>
&gt; &nbsp; &nbsp; 889 &nbsp; &nbsp; QPtrListIterator&lt;QWidget&gt; it(f-&gt;focusWidgets);<br>
&gt; &nbsp; &nbsp; 890 &nbsp; &nbsp; QWidget *w;<br>
&gt; &nbsp; &nbsp; 891 &nbsp; &nbsp; while ( (w = it.current()) ) {<br>
&gt; &nbsp; &nbsp; 892 &nbsp; &nbsp; &nbsp; &nbsp; ++it;<br>
&gt; &nbsp; &nbsp; 893 &nbsp; &nbsp; &nbsp; &nbsp; QWidget * p = w;<br>
&gt; &nbsp; &nbsp; 894 &nbsp; &nbsp; &nbsp; &nbsp; while( p &amp;&amp;
p != this )<br>
&gt; &nbsp; &nbsp; 895 &nbsp; &nbsp; &nbsp; &nbsp; p = p-&gt;parentWidget();<br>
&gt; &nbsp; &nbsp; 896 &nbsp; &nbsp; &nbsp; &nbsp; if ( p ) // my descendant<br>
&gt; &nbsp; &nbsp; 897 &nbsp; &nbsp; &nbsp; &nbsp; f-&gt;focusWidgets.removeRef(
w );<br>
&gt; &nbsp; &nbsp; 898 &nbsp; &nbsp; }<br>
&gt; &nbsp; &nbsp; 899 &nbsp; &nbsp; }<br>
&gt; <br>
</tt></font>