OSDN Git Service

libavformat/ffmetadec: Make unchanged function arguments const
authorMichael Niedermayer <michaelni@gmx.at>
Wed, 24 Sep 2014 16:33:55 +0000 (18:33 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Wed, 24 Sep 2014 17:17:55 +0000 (19:17 +0200)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/ffmetadec.c

index e4e9dda..e226406 100644 (file)
@@ -78,10 +78,11 @@ static AVChapter *read_chapter(AVFormatContext *s)
     return avpriv_new_chapter(s, s->nb_chapters, tb, start, end, NULL);
 }
 
-static uint8_t *unescape(uint8_t *buf, int size)
+static uint8_t *unescape(const uint8_t *buf, int size)
 {
     uint8_t *ret = av_malloc(size + 1);
-    uint8_t *p1  = ret, *p2 = buf;
+    uint8_t *p1  = ret;
+    const uint8_t *p2 = buf;
 
     if (!ret)
         return NULL;
@@ -95,9 +96,10 @@ static uint8_t *unescape(uint8_t *buf, int size)
     return ret;
 }
 
-static int read_tag(uint8_t *line, AVDictionary **m)
+static int read_tag(const uint8_t *line, AVDictionary **m)
 {
-    uint8_t *key, *value, *p = line;
+    uint8_t *key, *value;
+    const uint8_t *p = line;
 
     /* find first not escaped '=' */
     while (1) {