Bug 222954 - svg pixbuf loader memory leak
Summary: svg pixbuf loader memory leak
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: librsvg2
Version: 8
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Behdad Esfahbod
QA Contact:
URL:
Whiteboard: bzcl34nup
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-01-16 23:55 UTC by David Nečas
Modified: 2009-01-09 07:03 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-01-09 07:03:16 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
test program C source (443 bytes, text/plain)
2007-01-16 23:55 UTC, David Nečas
no flags Details

Description David Nečas 2007-01-16 23:55:45 UTC
Description of problem:
The SVG pixbuf loader that comes with librsvg2 can leak memory.

Version-Release number of selected component (if applicable):
librsvg2-2.16.1-1.fc6

How reproducible:
Always.

Steps to Reproduce:
1. Run the attached program under valgrind --leak-check=full
  
Actual results:
There is a definitely-lost memory leak reported with the same number of blocks
as the number of iterations:
==10231== 4800 bytes in 100 blocks are definitely lost in loss record 5 of 17
==10231==    at 0x4A04BA2: calloc (vg_replace_malloc.c:279)
==10231==    by 0x3954233D21: g_malloc0 (gmem.c:150)
==10231==    by 0x4D27025: gdk_pixbuf__svg_image_begin_load (io-svg.c:68)
==10231==    by 0x3956A091A3: gdk_pixbuf_loader_load_module
(gdk-pixbuf-loader.c:374)
==10231==    by 0x3956A098C0: gdk_pixbuf_loader_new_with_type
(gdk-pixbuf-loader.c:533)
==10231==    by 0x4007DC: main (pixbuf-svg-loader-leak.c:13)
==10231== 
==10231== 


Expected results:
No such leak report.


Additional info:
The leaked memory seems to be the context.  The !context->handle code path in
gdk_pixbuf__svg_image_stop_load() does not free the context.  I admit closing
the loader before the first write is not a typical use, see also bug 222951, I'm
not sure if it applies here.

Comment 1 David Nečas 2007-01-16 23:55:45 UTC
Created attachment 145761 [details]
test program C source

Comment 2 Bug Zapper 2008-04-04 05:37:58 UTC
Fedora apologizes that these issues have not been resolved yet. We're
sorry it's taken so long for your bug to be properly triaged and acted
on. We appreciate the time you took to report this issue and want to
make sure no important bugs slip through the cracks.

If you're currently running a version of Fedora Core between 1 and 6,
please note that Fedora no longer maintains these releases. We strongly
encourage you to upgrade to a current Fedora release. In order to
refocus our efforts as a project we are flagging all of the open bugs
for releases which are no longer maintained and closing them.
http://fedoraproject.org/wiki/LifeCycle/EOL

If this bug is still open against Fedora Core 1 through 6, thirty days
from now, it will be closed 'WONTFIX'. If you can reporduce this bug in
the latest Fedora version, please change to the respective version. If
you are unable to do this, please add a comment to this bug requesting
the change.

Thanks for your help, and we apologize again that we haven't handled
these issues to this point.

The process we are following is outlined here:
http://fedoraproject.org/wiki/BugZappers/F9CleanUp

We will be following the process here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping to ensure this
doesn't happen again.

And if you'd like to join the bug triage team to help make things
better, check out http://fedoraproject.org/wiki/BugZappers

Comment 3 David Nečas 2008-04-04 06:22:18 UTC
Well, it's nice that some robot apologizes but if a human being tried to run the
provided test case it would be even nicer.

So, yes, the output of the test case is the same as it were when the bug was
reported.  The bug is still relevant for F8.

Comment 4 Bug Zapper 2008-11-26 07:08:53 UTC
This message is a reminder that Fedora 8 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 8.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '8'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 8's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 8 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 5 Bug Zapper 2009-01-09 07:03:16 UTC
Fedora 8 changed to end-of-life (EOL) status on 2009-01-07. Fedora 8 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.


Note You need to log in before you can comment on or make changes to this bug.