forked from FFmpeg/FFmpeg
avutil/dict: Use av_dict_iterate in av_dict_copy
Signed-off-by: Anton Khirnov <anton@khirnov.net>
This commit is contained in:
parent
5f7c5a0bd7
commit
3c2050b749
1 changed files with 2 additions and 2 deletions
|
@ -236,9 +236,9 @@ void av_dict_free(AVDictionary **pm)
|
||||||
|
|
||||||
int av_dict_copy(AVDictionary **dst, const AVDictionary *src, int flags)
|
int av_dict_copy(AVDictionary **dst, const AVDictionary *src, int flags)
|
||||||
{
|
{
|
||||||
AVDictionaryEntry *t = NULL;
|
const AVDictionaryEntry *t = NULL;
|
||||||
|
|
||||||
while ((t = av_dict_get(src, "", t, AV_DICT_IGNORE_SUFFIX))) {
|
while ((t = av_dict_iterate(src, t))) {
|
||||||
int ret = av_dict_set(dst, t->key, t->value, flags);
|
int ret = av_dict_set(dst, t->key, t->value, flags);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
return ret;
|
return ret;
|
||||||
|
|
Loading…
Add table
Reference in a new issue