Commit ec4d761c authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/sonic: fix memleaks

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 8477e63d
......@@ -193,7 +193,7 @@ static int intlist_write(PutBitContext *pb, int *buf, int entries, int base_2_pa
bits = av_calloc(entries*max, sizeof(*bits));
if (!bits)
{
// av_free(copy);
av_free(copy);
return AVERROR(ENOMEM);
}
......@@ -249,8 +249,8 @@ static int intlist_write(PutBitContext *pb, int *buf, int entries, int base_2_pa
if (buf[i])
put_bits(pb, 1, buf[i] < 0);
// av_free(bits);
// av_free(copy);
av_free(bits);
av_free(copy);
return 0;
}
......@@ -341,7 +341,7 @@ static int intlist_read(GetBitContext *gb, int *buf, int entries, int base_2_par
pos++;
}
// av_free(bits);
av_free(bits);
// read signs
for (i = 0; i < entries; i++)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment