summaryrefslogtreecommitdiff
path: root/libavformat/rmdec.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavformat/rmdec.c')
-rw-r--r--libavformat/rmdec.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/rmdec.c b/libavformat/rmdec.c
index 222c43378c..e6a1fe8842 100644
--- a/libavformat/rmdec.c
+++ b/libavformat/rmdec.c
@@ -651,7 +651,8 @@ static int rm_read_header(AVFormatContext *s)
if (!data_off)
data_off = avio_tell(pb) - 18;
- if (indx_off && pb->seekable && !(s->flags & AVFMT_FLAG_IGNIDX) &&
+ if (indx_off && (pb->seekable & AVIO_SEEKABLE_NORMAL) &&
+ !(s->flags & AVFMT_FLAG_IGNIDX) &&
avio_seek(pb, indx_off, SEEK_SET) >= 0) {
rm_read_index(s);
avio_seek(pb, data_off + 18, SEEK_SET);