[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-perl
Subject: [Kde-perl] Issue with CheckTableItem
From: "Bernard Li" <bli () bcgsc ! ca>
Date: 2005-07-17 20:50:40
Message-ID: 36BEEFA2DF192944BF71E072F7A5F46518CDF2 () xchange1 ! phage ! bcgsc ! ca
[Download RAW message or body]
--===============1612618059==
Content-class: urn:content-classes:message
Content-Type: multipart/alternative;
boundary="----_=_NextPart_001_01C58B11.3158EFA5"
This is a multi-part message in MIME format.
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
[Attachment #3 (text/html)]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"><HTML \
DIR=ltr><HEAD><META HTTP-EQUIV="Content-Type" CONTENT="text/html; \
charset=iso-8859-1"></HEAD><BODY><DIV><FONT face='Arial' color=#0000ff size=2>Hi \
guys:</FONT></DIV> <DIV><FONT face=Arial color=#0000ff size=2></FONT> </DIV>
<DIV><FONT face=Arial color=#0000ff size=2>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:</FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2></FONT> </DIV>
<DIV><A href="http://fedora.redhat.com/docs/release-notes/fc3/x86/"><FONT
face=Arial
size=2>http://fedora.redhat.com/docs/release-notes/fc3/x86/</FONT></A></DIV>
<DIV><FONT face=Arial color=#0000ff size=2></FONT> </DIV>
<DIV><FONT face=Arial color=#0000ff size=2>Then search for 'glibc'.</FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2></FONT> </DIV>
<DIV><FONT face=Arial color=#0000ff size=2>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:</FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2></FONT> </DIV>
<DIV><FONT face=Arial color=#0000ff size=2>*** glibc detected *** double free or
corruption (fasttop): 0x092e0bd8 ***</FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2></FONT> </DIV>
<DIV><FONT face=Arial color=#0000ff size=2>Here's code snippet which can
reproduce the problem:</FONT></DIV><PRE>#!/usr/bin/perl -w</PRE><PRE>use \
strict;<BR>use Qt;</PRE><PRE>my $a = Qt::Application(\@ARGV);<BR>my $table = \
Qt::Table(5,5);</PRE><PRE>$table->setItem(0,1,Qt::CheckTableItem($table,"test1"));< \
/PRE><PRE>#$table->removeRow(0);<BR>#$table->takeItem($table->item(0,1));</PR \
E><PRE>$table->setItem(0,1,Qt::CheckTableItem($table,"test2"));</PRE><PRE>$a->setMainWidget($table);<BR>$table->show;<BR>exit \
$a->exec;</PRE> <DIV><FONT face=Arial color=#0000ff size=2>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.</FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2></FONT> </DIV>
<DIV><FONT face=Arial color=#0000ff size=2>I even tried setting MALLOC_CHECK_=0
(as suggested by the release notes), but that gave me segmentation fault
instead.</FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2></FONT> </DIV>
<DIV><FONT face=Arial color=#0000ff size=2>Thanks in advance for your
help.</FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2></FONT> </DIV>
<DIV><FONT face=Arial color=#0000ff size=2>Cheers,</FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2></FONT> </DIV>
<DIV><FONT face=Arial color=#0000ff size=2>Bernard</FONT></DIV></BODY></HTML>
_______________________________________________
Kde-perl mailing list
Kde-perl@kde.org
https://mail.kde.org/mailman/listinfo/kde-perl
--===============1612618059==--
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic