summaryrefslogtreecommitdiffstats
path: root/libhb/detelecine.c
diff options
context:
space:
mode:
authorjstebbins <[email protected]>2008-09-15 15:01:08 +0000
committerjstebbins <[email protected]>2008-09-15 15:01:08 +0000
commit34327d0c37880dcc2d4f332ce291a308ce767d8d (patch)
treeb853df933250647a16e1af5a22b1e830bd3ceb37 /libhb/detelecine.c
parent357a1d943389cb3c76bf3a2c412b6e86bf646cf7 (diff)
Fix a couple problem exposed through some valgrind testing. use of freed
memory in detelecine and use of uninitialized memory in decmpeg2 git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1700 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/detelecine.c')
-rw-r--r--libhb/detelecine.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/libhb/detelecine.c b/libhb/detelecine.c
index a305cb4d2..d3757cb69 100644
--- a/libhb/detelecine.c
+++ b/libhb/detelecine.c
@@ -567,15 +567,17 @@ void pullup_free_context( struct pullup_context * c )
free( c->buffers );
- f = c->head;
- do
+ f = c->head->next;
+ while( f != c->head )
{
free( f->diffs );
free( f->comb );
f = f->next;
free( f->prev );
}
- while( f != c->head );
+ free( f->diffs );
+ free( f->comb );
+ free(f);
free( c->frame );
free( c );