[Qt-interest] glibc detected 'corrupted double-linked list' due toa static QCursor member variable in installed eventHandler?

Tony Rietwyk tony.rietwyk at rightsoft.com.au
Mon May 25 04:52:17 CEST 2009


Hi Frank, 

You are installing the event filter on itself?  I doubt this action is
supported, and am surprised that you don't get warnings from Qt about it!
Why not just override QObject::event()?  What do you actually want to
achieve?  What error occurs in the destructor?  

Regards, 


> -----Original Message-----
> Using Qt4.4.2:
> 
> The following code crashes on exit:
> 
> MyClass::MyClass () {
> 	...
> 	installEventFilter (this)
> 	...
> }
> 
> bool MyClass::eventFilter (QObject * obj, QEvent * e) {
> 	static QCursor defaultCursor (Qt::ArrowCursor);
> 	return QObject::eventFilter (obj, e);
> }
> 
> This happens on linux only.
> Using a custom cursor or setting defaultCursor to a custom 
> cursor before d'tor 
> gets called fixes the problem.
> 
> Unfortunatelly it seems not to be reproducable in a simple example.
> 
> Has anybody else seen this behavior - so its worth filing a 
> bug report?
> 
> Thanx
> Frank




More information about the Qt-interest-old mailing list