Browse code

dict: fix assignment discards qualifiers from pointer target type warnings.

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

Michael Niedermayer authored on 2011/10/18 05:56:13
Showing 1 changed files
... ...
@@ -75,11 +75,11 @@ int av_dict_set(AVDictionary **pm, const char *key, const char *value, int flags
75 75
     }
76 76
     if (value) {
77 77
         if (flags & AV_DICT_DONT_STRDUP_KEY) {
78
-            m->elems[m->count].key  = key;
78
+            m->elems[m->count].key   = (char*)(intptr_t)key;
79 79
         } else
80 80
         m->elems[m->count].key  = av_strdup(key  );
81 81
         if (flags & AV_DICT_DONT_STRDUP_VAL) {
82
-            m->elems[m->count].value = value;
82
+            m->elems[m->count].value = (char*)(intptr_t)value;
83 83
         } else if (oldval && flags & AV_DICT_APPEND) {
84 84
             int len = strlen(oldval) + strlen(value) + 1;
85 85
             if (!(oldval = av_realloc(oldval, len)))