Commit cda5d89d authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/bitstream_filter: Use av_bitstream_filter_next() instead of direct...

avcodec/bitstream_filter: Use av_bitstream_filter_next() instead of direct access in av_bitstream_filter_init()
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 0eb4a428
......@@ -43,9 +43,9 @@ void av_register_bitstream_filter(AVBitStreamFilter *bsf)
AVBitStreamFilterContext *av_bitstream_filter_init(const char *name)
{
AVBitStreamFilter *bsf = first_bitstream_filter;
AVBitStreamFilter *bsf = NULL;
while (bsf) {
while (bsf = av_bitstream_filter_next(bsf)) {
if (!strcmp(name, bsf->name)) {
AVBitStreamFilterContext *bsfc =
av_mallocz(sizeof(AVBitStreamFilterContext));
......@@ -54,7 +54,6 @@ AVBitStreamFilterContext *av_bitstream_filter_init(const char *name)
bsf->priv_data_size ? av_mallocz(bsf->priv_data_size) : NULL;
return bsfc;
}
bsf = bsf->next;
}
return NULL;
}
......
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