From 42a894fc7da0404b07734ff5c7be4bdee4037e53 Mon Sep 17 00:00:00 2001 From: Rocky Bernstein Date: Sat, 21 Dec 2002 16:25:31 +0000 Subject: Protect against faulty configuration settings a tad better. CVS patchset: 3613 CVS date: 2002/12/21 16:25:31 --- src/xine-engine/configfile.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/xine-engine/configfile.c b/src/xine-engine/configfile.c index 76c3a293d..dff921e8b 100644 --- a/src/xine-engine/configfile.c +++ b/src/xine-engine/configfile.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: configfile.c,v 1.40 2002/10/31 16:58:15 mroi Exp $ + * $Id: configfile.c,v 1.41 2002/12/21 16:25:31 rockyb Exp $ * * config object (was: file) management - implementation * @@ -674,9 +674,12 @@ void xine_config_save (xine_t *xine_ro, const char *filename) { fprintf (f_config, "}, default: %d\n", entry->num_default); - fprintf (f_config, "%s:", entry->key); - fprintf (f_config, "%s\n", entry->enum_values[entry->num_value]); + if (entry->enum_values[entry->num_value] != NULL) { + fprintf (f_config, "%s:", entry->key); + fprintf (f_config, "%s\n", entry->enum_values[entry->num_value]); + } + fprintf (f_config, "\n"); break; } -- cgit v1.2.3