Commit 16b3d792 authored by aurel's avatar aurel

fall back mmap() call using MAP_PRIVATE for working on no-mmu systems

patch by Mike Frysinger   vapier.adi _at_ gmail.com


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@7380 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent c9167d40
......@@ -219,8 +219,11 @@ static int grab_read_header(AVFormatContext *s1, AVFormatParameters *ap)
} else {
s->video_buf = mmap(0,s->gb_buffers.size,PROT_READ|PROT_WRITE,MAP_SHARED,video_fd,0);
if ((unsigned char*)-1 == s->video_buf) {
perror("mmap");
goto fail;
s->video_buf = mmap(0,s->gb_buffers.size,PROT_READ|PROT_WRITE,MAP_PRIVATE,video_fd,0);
if ((unsigned char*)-1 == s->video_buf) {
perror("mmap");
goto fail;
}
}
s->gb_frame = 0;
s->time_frame = av_gettime() * s->frame_rate / s->frame_rate_base;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment