Oh,When I use ASF:File, it memory leak 2<br>Valgrind show the memory leak at<br><br>TagLib::ASF::File::HeaderExtensionObject::parse(TagLib::ASF::File*, unsigned int) <br><br>I was found other bug in MPEG, and busy doing it<br>
<br>Now I have the problem on it, memory leak:(<br><br><div class="gmail_quote">On 7 October 2010 18:00, <span dir="ltr"><<a href="mailto:taglib-devel-request@kde.org">taglib-devel-request@kde.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">Send taglib-devel mailing list submissions to<br>
<a href="mailto:taglib-devel@kde.org">taglib-devel@kde.org</a><br>
<br>
To subscribe or unsubscribe via the World Wide Web, visit<br>
<a href="https://mail.kde.org/mailman/listinfo/taglib-devel" target="_blank">https://mail.kde.org/mailman/listinfo/taglib-devel</a><br>
or, via email, send a message with subject or body 'help' to<br>
<a href="mailto:taglib-devel-request@kde.org">taglib-devel-request@kde.org</a><br>
<br>
You can reach the person managing the list at<br>
<a href="mailto:taglib-devel-owner@kde.org">taglib-devel-owner@kde.org</a><br>
<br>
When replying, please edit your Subject line so it is more specific<br>
than "Re: Contents of taglib-devel digest..."<br>
<br>
<br>
Today's Topics:<br>
<br>
1. TagLib::ASF::Tag::addAttribute possible memory leakage?<br>
(Anthony Liu)<br>
2. Re: TagLib::ASF::Tag::addAttribute possible memory leakage?<br>
(Luk?? Lalinsk?)<br>
<br>
<br>
----------------------------------------------------------------------<br>
<br>
Message: 1<br>
Date: Thu, 7 Oct 2010 14:32:02 +0800<br>
From: Anthony Liu <<a href="mailto:quadamage@gmail.com">quadamage@gmail.com</a>><br>
Subject: TagLib::ASF::Tag::addAttribute possible memory leakage?<br>
To: <a href="mailto:taglib-devel@kde.org">taglib-devel@kde.org</a><br>
Message-ID:<br>
<<a href="mailto:AANLkTimJxthgeFDViz3%2BfCZ0Tq4D-cEr1z3gyffJqWnY@mail.gmail.com">AANLkTimJxthgeFDViz3+fCZ0Tq4D-cEr1z3gyffJqWnY@mail.gmail.com</a>><br>
Content-Type: text/plain; charset="iso-8859-1"<br>
<br>
Hi to all.<br>
<br>
It appeals that TagLib::ASF::Tag::addAttribute has a memory leakage bug,<br>
<br>
ASF::File f( filename, false );<br>
<br>
ASF::Tag *asfTag = f.tag();<br>
<br>
<br>
> ASF::Attribute atb( ByteVector( 10000000, 0 ) );<br>
<br>
asfTag->addAttribute( "Test", atb );<br>
<br>
f.save();<br>
<br>
<br>
<br>
The above code will cause memory leakage, if you increase the size of the<br>
asf attribute, things get even worst.<br>
<br>
--<br>
Best Regards<br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <a href="http://mail.kde.org/pipermail/taglib-devel/attachments/20101007/20ce7aaf/attachment-0001.htm" target="_blank">http://mail.kde.org/pipermail/taglib-devel/attachments/20101007/20ce7aaf/attachment-0001.htm</a><br>
<br>
------------------------------<br>
<br>
Message: 2<br>
Date: Thu, 7 Oct 2010 10:23:14 +0200<br>
From: Luk?? Lalinsk? <<a href="mailto:lalinsky@gmail.com">lalinsky@gmail.com</a>><br>
Subject: Re: TagLib::ASF::Tag::addAttribute possible memory leakage?<br>
To: <a href="mailto:taglib-devel@kde.org">taglib-devel@kde.org</a><br>
Message-ID:<br>
<<a href="mailto:AANLkTimQCWvtAtuZeoZ8D%2BG6YfjeHpQpK0p2YvOQJiQ2@mail.gmail.com">AANLkTimQCWvtAtuZeoZ8D+G6YfjeHpQpK0p2YvOQJiQ2@mail.gmail.com</a>><br>
Content-Type: text/plain; charset=ISO-8859-1<br>
<br>
On Thu, Oct 7, 2010 at 8:32 AM, Anthony Liu <<a href="mailto:quadamage@gmail.com">quadamage@gmail.com</a>> wrote:<br>
> Hi to all.<br>
> It appeals that?TagLib::ASF::Tag::addAttribute has a memory leakage bug,<br>
><br>
>> ASF::File f( filename, false );<br>
>><br>
>> ASF::Tag *asfTag = f.tag();<br>
>><br>
>> ASF::Attribute atb( ByteVector( 10000000, 0 ) );<br>
>><br>
>> asfTag->addAttribute( "Test", ?atb );<br>
>><br>
>> ?? ? ? ?f.save();<br>
><br>
> The above code will cause memory leakage, if you increase the size of the<br>
> asf attribute, things get even worst.<br>
<br>
Can you please be more specific? Valgrind on examples/tagreader<br>
reports no real memory leaks when running on a WMA file. Everything in<br>
ASF::Attribute is reference-counted, it will get deleted when the last<br>
instance runs out of context.<br>
<br>
Lukas<br>
<br>
<br>
------------------------------<br>
<br>
_______________________________________________<br>
taglib-devel mailing list<br>
<a href="mailto:taglib-devel@kde.org">taglib-devel@kde.org</a><br>
<a href="https://mail.kde.org/mailman/listinfo/taglib-devel" target="_blank">https://mail.kde.org/mailman/listinfo/taglib-devel</a><br>
<br>
<br>
End of taglib-devel Digest, Vol 76, Issue 1<br>
*******************************************<br>
</blockquote></div><br><br clear="all"><br>-- <br>Blog<br><a href="http://b.freefcw.com">http://b.freefcw.com</a><br><br>Twitter<br><a href="http://twitter.com/freefcw">http://twitter.com/freefcw</a><br><br> 巫山霏云<br>
<br>