From 5859b4076e5326996aa21e6fc0ce572edebec469 Mon Sep 17 00:00:00 2001 From: Darren Salt Date: Tue, 2 May 2006 21:19:32 +0000 Subject: Fix a null dereference which occurs if enabling deinterlacing when onefield_xv is selected and no frames have yet been processed. CVS patchset: 7984 CVS date: 2006/05/02 21:19:32 --- src/video_out/video_out_xv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/video_out/video_out_xv.c b/src/video_out/video_out_xv.c index ec698d95c..1b093b041 100644 --- a/src/video_out/video_out_xv.c +++ b/src/video_out/video_out_xv.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: video_out_xv.c,v 1.215 2006/01/27 07:46:15 tmattern Exp $ + * $Id: video_out_xv.c,v 1.216 2006/05/02 21:19:32 dsalt Exp $ * * video_out_xv.c, X11 video extension interface for xine * @@ -616,7 +616,7 @@ static void xv_compute_output_size (xv_driver_t *this) { /* onefield_xv divide by 2 the number of lines */ if (this->deinterlace_enabled && (this->deinterlace_method == DEINTERLACE_ONEFIELDXV) - && (this->cur_frame->format == XINE_IMGFMT_YV12)) { + && this->cur_frame && (this->cur_frame->format == XINE_IMGFMT_YV12)) { this->sc.displayed_height = this->sc.displayed_height / 2 - 1; this->sc.displayed_yoffset = this->sc.displayed_yoffset / 2; } -- cgit v1.2.3