Mercurial > libavformat.hg
diff flvdec.c @ 5982:f74198942337 libavformat
Mark av_metadata_set() as deprecated, and use av_metadata_set2()
in its place.
av_metadata_set() is going to be dropped at the next major bump.
author | stefano |
---|---|
date | Sun, 25 Apr 2010 14:27:42 +0000 |
parents | 12bdd63f5259 |
children | da46dcc05d4a |
line wrap: on
line diff
--- a/flvdec.c Thu Apr 22 20:34:30 2010 +0000 +++ b/flvdec.c Sun Apr 25 14:27:42 2010 +0000 @@ -188,17 +188,17 @@ if(amf_type == AMF_DATA_TYPE_BOOL) { av_strlcpy(str_val, num_val > 0 ? "true" : "false", sizeof(str_val)); - av_metadata_set(&s->metadata, key, str_val); + av_metadata_set2(&s->metadata, key, str_val, 0); } else if(amf_type == AMF_DATA_TYPE_NUMBER) { snprintf(str_val, sizeof(str_val), "%.f", num_val); - av_metadata_set(&s->metadata, key, str_val); + av_metadata_set2(&s->metadata, key, str_val, 0); if(!strcmp(key, "duration")) s->duration = num_val * AV_TIME_BASE; else if(!strcmp(key, "videodatarate") && vcodec && 0 <= (int)(num_val * 1024.0)) vcodec->bit_rate = num_val * 1024.0; else if(!strcmp(key, "audiodatarate") && acodec && 0 <= (int)(num_val * 1024.0)) acodec->bit_rate = num_val * 1024.0; } else if (amf_type == AMF_DATA_TYPE_STRING) - av_metadata_set(&s->metadata, key, str_val); + av_metadata_set2(&s->metadata, key, str_val, 0); } return 0;