Merge commit '0e2395293bff089536b97131b32fea8b58bca0ba'
authorHendrik Leppkes <h.leppkes@gmail.com>
Sun, 29 Nov 2015 15:17:36 +0000 (16:17 +0100)
committerHendrik Leppkes <h.leppkes@gmail.com>
Sun, 29 Nov 2015 15:17:36 +0000 (16:17 +0100)
* commit '0e2395293bff089536b97131b32fea8b58bca0ba':
  nut: Mark non-fatal errors as warnings

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
1  2 
libavformat/nutdec.c

@@@ -597,13 -531,10 +597,15 @@@ static int decode_info_header(NUTContex
              type = "v";
          }
  
 +        if (ret < 0) {
 +            av_log(s, AV_LOG_ERROR, "get_str failed while decoding info header\n");
 +            return ret;
 +        }
 +
          if (stream_id_plus1 > s->nb_streams) {
-             av_log(s, AV_LOG_ERROR, "invalid stream id for info packet\n");
+             av_log(s, AV_LOG_WARNING,
+                    "invalid stream id %d for info packet\n",
+                    stream_id_plus1);
              continue;
          }
  
@@@ -712,10 -615,7 +714,10 @@@ static int find_and_decode_index(NUTCon
      avio_seek(bc, filesize - 12, SEEK_SET);
      avio_seek(bc, filesize - avio_rb64(bc), SEEK_SET);
      if (avio_rb64(bc) != INDEX_STARTCODE) {
-         av_log(s, AV_LOG_ERROR, "no index at the end\n");
+         av_log(s, AV_LOG_WARNING, "no index at the end\n");
 +
 +        if(s->duration<=0)
 +            s->duration = find_duration(nut, filesize);
          return ret;
      }