diff --git a/libavcodec/options.c b/libavcodec/options.c index d1cc183050..76ca66c902 100644 --- a/libavcodec/options.c +++ b/libavcodec/options.c @@ -580,13 +580,13 @@ int avcodec_get_context_defaults3(AVCodecContext *s, AVCodec *codec){ } } if(codec->priv_class){ - *(AVClass**)s->priv_data= codec->priv_class; + *(const AVClass**)s->priv_data = codec->priv_class; av_opt_set_defaults(s->priv_data); } } if (codec && codec->defaults) { int ret; - AVCodecDefault *d = codec->defaults; + const AVCodecDefault *d = codec->defaults; while (d->key) { ret = av_set_string3(s, d->key, d->value, 0, NULL); av_assert0(ret >= 0);