diff -Naur MPlayer-0.90rc5.orig/libvo/vo_vesa.c MPlayer-0.90rc5/libvo/vo_vesa.c --- MPlayer-0.90rc5.orig/libvo/vo_vesa.c 2003-03-26 00:14:55.000000000 +0100 +++ MPlayer-0.90rc5/libvo/vo_vesa.c 2003-03-26 00:24:55.000000000 +0100 @@ -115,8 +115,10 @@ /* Linux Video Overlay */ static const char *lvo_name = NULL; +static int lvo_opened = 0; #ifdef CONFIG_VIDIX static const char *vidix_name = NULL; +static int vidix_opened = 0; #endif #define HAS_DGA() (win.idx == -1) @@ -150,9 +152,9 @@ static void vesa_term( void ) { int err; - if(lvo_name) vlvo_term(); + if(lvo_opened) { vlvo_term(); lvo_opened = 0; } #ifdef CONFIG_VIDIX - else if(vidix_name) vidix_term(); + else if(vidix_opened) { vidix_term(); vidix_opened = 0; } #endif if(init_state) if((err=vbeRestoreState(init_state)) != VBE_OK) PRINT_VBE_ERR("vbeRestoreState",err); init_state=NULL; @@ -935,11 +937,11 @@ if(vlvo_init(width,height,x_offset,y_offset,dstW,dstH,format,dstBpp) != 0) { printf("vo_vesa: Can't initialize Linux Video Overlay\n"); - lvo_name = NULL; vesa_term(); return -1; } else printf("vo_vesa: Using video overlay: %s\n",lvo_name); + lvo_opened = 1; } #ifdef CONFIG_VIDIX else @@ -950,12 +952,12 @@ video_mode_info.XResolution,video_mode_info.YResolution) != 0) { printf("vo_vesa: Can't initialize VIDIX driver\n"); - vidix_name = NULL; vesa_term(); return -1; } else printf("vo_vesa: Using VIDIX\n"); vidix_start(); + vidix_opened = 1; } #endif }