# HG changeset patch # User michael # Date 1171680407 0 # Node ID 3edc6f0468bea4003b970cfc7dee40f9543c98d2 # Parent 0dc3a767943d08fbf1d5a0b9c72e228258ffad97 not checking error return, resulting double free returning uninitalized pointers diff -r 0dc3a767943d -r 3edc6f0468be ipmovie.c --- a/ipmovie.c Thu Feb 15 15:39:39 2007 +0000 +++ b/ipmovie.c Sat Feb 17 02:46:47 2007 +0000 @@ -227,7 +227,7 @@ /* see if there are any pending packets */ chunk_type = load_ipmovie_packet(s, pb, pkt); - if ((chunk_type == CHUNK_VIDEO) && (chunk_type != CHUNK_DONE)) + if (chunk_type != CHUNK_DONE) return chunk_type; /* read the next chunk, wherever the file happens to be pointing */ @@ -601,8 +601,10 @@ ret = AVERROR_IO; else if (ret == CHUNK_NOMEM) ret = AVERROR_NOMEM; + else if (ret == CHUNK_VIDEO) + ret = 0; else - ret = 0; + ret = -1; return ret; }