[FFmpeg-cvslog] avutil/dict: add warning to docs about invalidating existing entries when adding a new entry

Marton Balint git at videolan.org
Tue Mar 15 01:02:39 CET 2016


ffmpeg | branch: master | Marton Balint <cus at passwd.hu> | Sat Feb  6 17:43:03 2016 +0100| [c3c7a879baea59bbc27d750b7e29264f87063598] | committer: Marton Balint

avutil/dict: add warning to docs about invalidating existing entries when adding a new entry

Reviewed-by: Michael Niedermayer <michael at niedermayer.cc>
Signed-off-by: Marton Balint <cus at passwd.hu>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=c3c7a879baea59bbc27d750b7e29264f87063598
---

 libavutil/dict.h |    3 +++
 1 file changed, 3 insertions(+)

diff --git a/libavutil/dict.h b/libavutil/dict.h
index b0aa784..542d540 100644
--- a/libavutil/dict.h
+++ b/libavutil/dict.h
@@ -116,6 +116,9 @@ int av_dict_count(const AVDictionary *m);
  * Note: If AV_DICT_DONT_STRDUP_KEY or AV_DICT_DONT_STRDUP_VAL is set,
  * these arguments will be freed on error.
  *
+ * Warning: Adding a new entry to a dictionary invalidates all existing entries
+ * previously returned with av_dict_get.
+ *
  * @param pm pointer to a pointer to a dictionary struct. If *pm is NULL
  * a dictionary struct is allocated and put in *pm.
  * @param key entry key to add to *pm (will be av_strduped depending on flags)



More information about the ffmpeg-cvslog mailing list