summaryrefslogtreecommitdiffstats
path: root/dec_video.c
diff options
context:
space:
mode:
authorjkeil <jkeil@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-07-20 11:35:47 +0000
committerjkeil <jkeil@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-07-20 11:35:47 +0000
commit59e817ef884c4c81d2b0e8b69012466ef0c06f74 (patch)
tree6b76a0aa5718fe8a7b53095e8eddd4550318d946 /dec_video.c
parent9df40837ed17b9e56c69bd1c1b8e7f125dd6ce27 (diff)
downloadmpv-59e817ef884c4c81d2b0e8b69012466ef0c06f74.tar.bz2
mpv-59e817ef884c4c81d2b0e8b69012466ef0c06f74.tar.xz
Fix segfault in DShow video decoder. Using directshow, the
sh_video->out_out_buffer is NULL on the first few decoded frames, and is initialized in loader/DirectShow/outputpin.cpp, method COutputPin::Receive(), while the video is already running. Do not try to display a frame while sh_video->out_out_buffer is still NULL. Such a test was present in the previous to last revision of this file, but was lost in the last revision. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@1363 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'dec_video.c')
-rw-r--r--dec_video.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/dec_video.c b/dec_video.c
index 29b63063cc..3d050c672a 100644
--- a/dec_video.c
+++ b/dec_video.c
@@ -332,7 +332,7 @@ switch(sh_video->codec->driver){
#ifdef USE_DIRECTSHOW
case 4: { // W32/DirectShow
if(drop_frame<2) DS_VideoDecoder_DecodeFrame(start, in_size, 0, !drop_frame);
- if(!drop_frame) blit_frame=3;
+ if(!drop_frame && sh_video->our_out_buffer) blit_frame=3;
break;
}
#endif