Commit 72f4f8a6 authored by Timothy B. Terriberry's avatar Timothy B. Terriberry

Fix free with uninitialized data in opus_tags_parse().

If the parsing fails before all comments are filled in, we will
 attempt to free any binary metadata at the position one past the
 last comment, which will be uninitialized.
Introduced in commit 0221ca95.
parent bd607f5c
......@@ -199,6 +199,7 @@ static int opus_tags_parse_impl(OpusTags *_tags,
if(_tags->user_comments[ci]==NULL)return OP_EFAULT;
_tags->comment_lengths[ci]=(int)count;
_tags->comments=ci+1;
_tags->user_comments[ci+1]=NULL;
}
_data+=count;
len-=count;
......
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