[Kde-perl] Issue with CheckTableItem

Bernard Li bli at bcgsc.ca
Sun Jul 17 22:50:40 CEST 2005


Hi guys:
 
I am having problems with using CheckTableItem on systems with newer glibc, namely Fedora Core 3 and Red Hat Enterprise Linux 4, please see the following release notes:
 
http://fedora.redhat.com/docs/release-notes/fc3/x86/ <http://fedora.redhat.com/docs/release-notes/fc3/x86/> 
 
Then search for 'glibc'.
 
Basically what happens, is if I use setItem on a table cell, and then execute another setItem on the same table cell, it would give me an error like the following, and crash the widget:
 
*** glibc detected *** double free or corruption (fasttop): 0x092e0bd8 ***
 
Here's code snippet which can reproduce the problem:
#!/usr/bin/perl -w
use strict;
use Qt;
my $a = Qt::Application(\@ARGV);
my $table = Qt::Table(5,5);
$table->setItem(0,1,Qt::CheckTableItem($table,"test1"));
#$table->removeRow(0);
#$table->takeItem($table->item(0,1));
$table->setItem(0,1,Qt::CheckTableItem($table,"test2"));
$a->setMainWidget($table);
$table->show;
exit $a->exec;
Same thing happens if I uncomment the line with 'removeRow', but it works fine if I uncomment the line with 'takeItem'.  Am I doing something wrong here?  The problem happens on version 3.008, and have also been tested with the latest 3.009b2.
 
I even tried setting MALLOC_CHECK_=0 (as suggested by the release notes), but that gave me segmentation fault instead.
 
Thanks in advance for your help.
 
Cheers,
 
Bernard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/kde-perl/attachments/20050717/1f16e7ef/attachment.html


More information about the Kde-perl mailing list