summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2020-08-22 20:46:45 +0200
committerwm4 <wm4@nowhere>2020-08-22 20:46:45 +0200
commit85f38a9765303a79650013591334e89f9047d4e7 (patch)
tree6d3db88584f66219fbedc46e72fd3c8b4521db5c
parentc06577e291aaf598981be2b0c3999ea04da31d82 (diff)
downloadmpv-85f38a9765303a79650013591334e89f9047d4e7.tar.bz2
mpv-85f38a9765303a79650013591334e89f9047d4e7.tar.xz
demux_mf: actually report errors
Well, whatever. Only results in an error message being printed, because there is no other error reporting mechanism, and the general policy is to keep trying with the rest of the data (i.e. not report EOF).
-rw-r--r--demux/demux_mf.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/demux/demux_mf.c b/demux/demux_mf.c
index ef5a5131bd..161e0cb92d 100644
--- a/demux/demux_mf.c
+++ b/demux/demux_mf.c
@@ -194,6 +194,7 @@ static bool demux_mf_read_packet(struct demuxer *demuxer,
mf_t *mf = demuxer->priv;
if (mf->curr_frame >= mf->nr_of_files)
return false;
+ bool ok = false;
struct stream *entry_stream = NULL;
if (mf->streams)
@@ -218,6 +219,7 @@ static bool demux_mf_read_packet(struct demuxer *demuxer,
dp->keyframe = true;
dp->stream = mf->sh->index;
*pkt = dp;
+ ok = true;
}
}
talloc_free(data.start);
@@ -227,6 +229,10 @@ static bool demux_mf_read_packet(struct demuxer *demuxer,
free_stream(stream);
mf->curr_frame++;
+
+ if (!ok)
+ MP_ERR(demuxer, "error reading image file\n");
+
return true;
}