[FFmpeg-cvslog] Fix " passing argument 1 of av_free discards const qualifier from pointer target type "

Michael Niedermayer git at videolan.org
Sat Sep 13 22:38:28 CEST 2014


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Tue Sep  9 21:07:58 2014 +0200| [8407cbbfc942343d562d5960f3b85938db49fac7] | committer: Michael Niedermayer

Fix "passing argument 1 of av_free discards const qualifier from pointer target type"

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

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

 libavutil/dict.c |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/libavutil/dict.c b/libavutil/dict.c
index bdb5690..475e906 100644
--- a/libavutil/dict.c
+++ b/libavutil/dict.c
@@ -77,8 +77,8 @@ int av_dict_set(AVDictionary **pm, const char *key, const char *value,
 
     if (tag) {
         if (flags & AV_DICT_DONT_OVERWRITE) {
-            if (flags & AV_DICT_DONT_STRDUP_KEY) av_free(key);
-            if (flags & AV_DICT_DONT_STRDUP_VAL) av_free(value);
+            if (flags & AV_DICT_DONT_STRDUP_KEY) av_free((void*)key);
+            if (flags & AV_DICT_DONT_STRDUP_VAL) av_free((void*)value);
             return 0;
         }
         if (flags & AV_DICT_APPEND)
@@ -126,8 +126,8 @@ err_out:
         av_free(m->elems);
         av_freep(pm);
     }
-    if (flags & AV_DICT_DONT_STRDUP_KEY) av_free(key);
-    if (flags & AV_DICT_DONT_STRDUP_VAL) av_free(value);
+    if (flags & AV_DICT_DONT_STRDUP_KEY) av_free((void*)key);
+    if (flags & AV_DICT_DONT_STRDUP_VAL) av_free((void*)value);
     return AVERROR(ENOMEM);
 }
 



More information about the ffmpeg-cvslog mailing list