summaryrefslogtreecommitdiffstats
path: root/libhb/reader.c
diff options
context:
space:
mode:
authorjstebbins <[email protected]>2011-02-12 21:38:34 +0000
committerjstebbins <[email protected]>2011-02-12 21:38:34 +0000
commit8bf55ae1a275b3576971c4596c4b0b1090902364 (patch)
tree754846425d4660147e7d658cf500359c7298866d /libhb/reader.c
parent335e7e305d59063132ddae2fff76e7c6c7b02d47 (diff)
plug some memory leaks.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3797 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/reader.c')
-rw-r--r--libhb/reader.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libhb/reader.c b/libhb/reader.c
index 783535492..bd3758eea 100644
--- a/libhb/reader.c
+++ b/libhb/reader.c
@@ -84,9 +84,14 @@ static void push_buf( const hb_reader_t *r, hb_fifo_t *fifo, hb_buffer_t *buf )
if ( hb_fifo_full_wait( fifo ) )
{
hb_fifo_push( fifo, buf );
+ buf = NULL;
break;
}
}
+ if ( buf )
+ {
+ hb_buffer_close( &buf );
+ }
}
static int is_audio( hb_reader_t *r, int id )