summaryrefslogtreecommitdiffstats
path: root/libmpdemux
diff options
context:
space:
mode:
authorarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-11-13 21:11:10 +0000
committerarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-11-13 21:11:10 +0000
commitcab56fc5f5e764d867bb480c7477584f4950e7cc (patch)
tree39addfdb361ed82e4e6ab5f7635b78e528c9e494 /libmpdemux
parent923580762e6d2a3e05abf5e0d5ef660cbb1496ff (diff)
downloadmpv-cab56fc5f5e764d867bb480c7477584f4950e7cc.tar.bz2
mpv-cab56fc5f5e764d867bb480c7477584f4950e7cc.tar.xz
ignore mov detection if first chunk bad
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@2880 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux')
-rw-r--r--libmpdemux/demux_mov.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libmpdemux/demux_mov.c b/libmpdemux/demux_mov.c
index f1499495d3..31e4376b4c 100644
--- a/libmpdemux/demux_mov.c
+++ b/libmpdemux/demux_mov.c
@@ -158,6 +158,7 @@ typedef struct {
int mov_check_file(demuxer_t* demuxer){
int flags=0;
+ int no=0;
mov_priv_t* priv=malloc(sizeof(mov_priv_t));
mp_msg(MSGT_DEMUX,MSGL_V,"Checking for MOV\n");
@@ -187,11 +188,14 @@ int mov_check_file(demuxer_t* demuxer){
/* unused, if you edit a mov, you can use space provided by free atoms (redefining it) */
break;
case MOV_FOURCC('w','i','d','e'):
+ break;
default:
+ if(no==0) return 0; // first chunk is bad!
id = bswap_32(id);
mp_msg(MSGT_DEMUX,MSGL_V,"MOV: unknown chunk: %.4s %d\n",&id,(int)len);
}
if(!stream_skip(demuxer->stream,len-8)) break;
+ ++no;
}
if(flags==1)