summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2010-12-11 18:37:00 +0000
committerUoti Urpala <uau@glyph.nonexistent.invalid>2010-12-16 06:22:18 +0200
commitad144017204a7537a9b95712541e7425d6722763 (patch)
tree24c7150217b53fa551adb43512eaa56476793395
parentd34257b5a3ec9d1b9884b68424573b14b9d131e9 (diff)
downloadmpv-ad144017204a7537a9b95712541e7425d6722763.tar.bz2
mpv-ad144017204a7537a9b95712541e7425d6722763.tar.xz
vd_ffmpeg: Reset ctx->vo_initialized to 0 on a resolution change
Otherwise we might think the filter chain/vo is ready when it actually is not, leading to a crash. Fixes crash part of bug 1156. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32690 b3059339-0415-0410-9bf9-f77b7e298cf2
-rw-r--r--libmpcodecs/vd_ffmpeg.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libmpcodecs/vd_ffmpeg.c b/libmpcodecs/vd_ffmpeg.c
index 0096737fdf..a874b8411c 100644
--- a/libmpcodecs/vd_ffmpeg.c
+++ b/libmpcodecs/vd_ffmpeg.c
@@ -473,6 +473,7 @@ static int init_vo(sh_video_t *sh, enum PixelFormat pix_fmt){
pix_fmt != ctx->pix_fmt ||
!ctx->vo_initialized)
{
+ ctx->vo_initialized = 0;
mp_msg(MSGT_DECVIDEO, MSGL_V, "[ffmpeg] aspect_ratio: %f\n", aspect);
// Do not overwrite s->aspect on the first call, so that a container