src/io/source_avcodec.c: always mark eof on error
authorPaul Brossier <piem@piem.org>
Fri, 17 Mar 2017 17:33:42 +0000 (18:33 +0100)
committerPaul Brossier <piem@piem.org>
Fri, 17 Mar 2017 17:33:42 +0000 (18:33 +0100)
src/io/source_avcodec.c

index 6335df6..a17d1a3 100644 (file)
@@ -356,6 +356,7 @@ void aubio_source_avcodec_readframe(aubio_source_avcodec_t *s, uint_t * read_sam
       char errorstr[256];
       av_strerror (err, errorstr, sizeof(errorstr));
       AUBIO_ERR("source_avcodec: could not read frame in %s (%s)\n", s->path, errorstr);
       char errorstr[256];
       av_strerror (err, errorstr, sizeof(errorstr));
       AUBIO_ERR("source_avcodec: could not read frame in %s (%s)\n", s->path, errorstr);
+      s->eof = 1;
       goto beach;
     }
   } while (avPacket.stream_index != s->selected_stream);
       goto beach;
     }
   } while (avPacket.stream_index != s->selected_stream);