# HG changeset patch # User michael # Date 1103487955 0 # Node ID d4f80b13d9810f5d907afeca5395c85d68fa35ee # Parent d3baee10d526d7692031354b35f934ea973f93fa 10l (double free) diff -r d3baee10d526 -r d4f80b13d981 img2.c --- a/img2.c Sun Dec 19 02:55:40 2004 +0000 +++ b/img2.c Sun Dec 19 20:25:55 2004 +0000 @@ -155,7 +155,6 @@ st = av_new_stream(s1, 0); if (!st) { - av_free(s); return -ENOMEM; } @@ -181,7 +180,7 @@ if (!s->is_pipe) { if (find_image_range(&first_index, &last_index, s->path) < 0) - goto fail; + return AVERROR_IO; s->img_first = first_index; s->img_last = last_index; s->img_number = first_index; @@ -204,10 +203,6 @@ } return 0; - - fail: - av_free(s); - return AVERROR_IO; } static int img_read_packet(AVFormatContext *s1, AVPacket *pkt)