]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/ilbc.c
avformat/matroskadec: fix the type of the TrackLanguage
[ffmpeg] / libavformat / ilbc.c
index 50e3c3cc769d56b5bbb82e06da47087f9fb12b80..d41027174db8c8b6eba92695914040a9a7853968 100644 (file)
@@ -49,7 +49,6 @@ static int ilbc_write_header(AVFormatContext *s)
         av_log(s, AV_LOG_ERROR, "Unsupported mode\n");
         return AVERROR(EINVAL);
     }
-    avio_flush(pb);
     return 0;
 }
 
@@ -59,7 +58,7 @@ static int ilbc_write_packet(AVFormatContext *s, AVPacket *pkt)
     return 0;
 }
 
-static int ilbc_probe(AVProbeData *p)
+static int ilbc_probe(const AVProbeData *p)
 {
     // Only check for "#!iLBC" which matches both formats
     if (!memcmp(p->buf, mode20_header, 6))
@@ -112,7 +111,6 @@ static int ilbc_read_packet(AVFormatContext *s,
     pkt->pos = avio_tell(s->pb);
     pkt->duration = par->block_align == 38 ? 160 : 240;
     if ((ret = avio_read(s->pb, pkt->data, par->block_align)) != par->block_align) {
-        av_packet_unref(pkt);
         return ret < 0 ? ret : AVERROR(EIO);
     }