[vlc-devel] commit: Fix potential memleak (CID 260) ( Rémi Duraffort )
git version control
git at videolan.org
Fri Oct 10 01:45:21 CEST 2008
vlc | branch: 0.9-bugfix | Rémi Duraffort <ivoire at videolan.org> | Wed Oct 8 22:05:46 2008 +0200| [da7df728472caeb010eac27471871741518ab8eb] | committer: Derk-Jan Hartman
Fix potential memleak (CID 260)
(cherry picked from commit cb89f6d527dc6920152c0a4248153bcb79221458)
Signed-off-by: Derk-Jan Hartman <hartman at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=da7df728472caeb010eac27471871741518ab8eb
---
modules/demux/subtitle.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/modules/demux/subtitle.c b/modules/demux/subtitle.c
index 3f029cb..730d3bc 100644
--- a/modules/demux/subtitle.c
+++ b/modules/demux/subtitle.c
@@ -1898,7 +1898,10 @@ static int ParseRealText( demux_t *p_demux, subtitle_t *p_subtitle, int i_idx )
const char *s = TextGetLine( txt );
if( !s )
+ {
+ free( psz_text );
return VLC_EGENERIC;
+ }
int i_len = strlen( s );
if( i_len == 0 ) break;
More information about the vlc-devel
mailing list