changeset 17900:5075cd9bb631

Don't try to parse fb.modes more than once. Fixes playback of multiple files with mplayer -vm
author pacman
date Mon, 20 Mar 2006 22:07:30 +0000
parents 7f055f2fb27f
children 51571591d56f
files libvo/vo_fbdev.c
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libvo/vo_fbdev.c	Mon Mar 20 21:13:01 2006 +0000
+++ b/libvo/vo_fbdev.c	Mon Mar 20 22:07:30 2006 +0000
@@ -162,6 +162,10 @@
 	int in_mode_def = 0;
 	int tmp, i;
 
+	/* If called more than once, reuse parsed data */
+	if (nr_modes)
+		return nr_modes;
+
 	mp_msg(MSGT_VO, MSGL_V, "Reading %s: ", cfgfile);
 
 	if ((fp = fopen(cfgfile, "r")) == NULL) {