Revision f16dd7e6

View differences:

cmdutils.c
224 224
        const char *str= av_get_string(opts_ctx, opt_names[i], &opt, buf, sizeof(buf));
225 225
        /* if an option with name opt_names[i] is present in opts_ctx then str is non-NULL */
226 226
        if(str && ((opt->flags & flags) == flags))
227
            av_set_string2(ctx, opt_names[i], str, 1);
227
            av_set_string3(ctx, opt_names[i], str, 1, NULL);
228 228
    }
229 229
}
230 230

  
ffserver.c
3735 3735
static int ffserver_opt_default(const char *opt, const char *arg,
3736 3736
                       AVCodecContext *avctx, int type)
3737 3737
{
3738
    const AVOption *o  = NULL;
3738
    int ret = 0;
3739 3739
    const AVOption *o2 = av_find_opt(avctx, opt, NULL, type, type);
3740 3740
    if(o2)
3741
        o = av_set_string2(avctx, opt, arg, 1);
3742
    if(!o)
3743
        return -1;
3744
    return 0;
3741
        ret = av_set_string3(avctx, opt, arg, 1, NULL);
3742
    return ret;
3745 3743
}
3746 3744

  
3747 3745
static int parse_ffconfig(const char *filename)
libavcodec/opt.c
207 207
}
208 208

  
209 209
const AVOption *av_set_string(void *obj, const char *name, const char *val){
210
    return av_set_string2(obj, name, val, 0);
210
    const AVOption *o;
211
    if (av_set_string3(obj, name, val, 0, &o) < 0)
212
        return NULL;
213
    return o;
211 214
}
212 215

  
213 216
const AVOption *av_set_double(void *obj, const char *name, double n){

Also available in: Unified diff