[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
patches to avoid memory leaks in sd_ibmtts
From: |
Chris Brannon |
Subject: |
patches to avoid memory leaks in sd_ibmtts |
Date: |
Sun, 28 Feb 2010 20:59:02 -0600 |
Jose Vilmar Estacio de Souza wrote:
> A while bak I posted in the list a message telling about use of memory=20
> by sd_ibmtts.
> I believe I have found part of the problem.
> Attached two patches that tries to alleviate the problem.
I haven't looked at all of your code; I will tomorrow.
You can get rid of the info variable from module_init
and module_audio_init_spd. It isn't used for anything.
In module_init from ibmtts.c, here are the only two places where info is used:
Declared at line 406,
and set to g_string_new("") at line 414.
You should be able to just delete both of those.
In module_audio_init_spd, here are the places where info is used:
declared at line 1119,
set to g_string_new("") at line 1124,
used as the first argument to g_string_append_printf at line 1197.
Again, you should be able to just delete all three of occurrences.
Line 1197 of module_utils.c is interesting. That is an error message,
and my first thought is that it needs to be propagated to the caller,
via the status_info argument.
However, abort is called, so it really doesn't matter.
-- Chris