summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRocky Bernstein <rockyb@users.sourceforge.net>2002-12-21 16:25:31 +0000
committerRocky Bernstein <rockyb@users.sourceforge.net>2002-12-21 16:25:31 +0000
commit42a894fc7da0404b07734ff5c7be4bdee4037e53 (patch)
treee17b3b3649dfc81a23569278d69827ddf7bae3ff
parenta03bd83d6da72dd2a6b702c0c990bf0cf5e2c8aa (diff)
downloadxine-lib-42a894fc7da0404b07734ff5c7be4bdee4037e53.tar.gz
xine-lib-42a894fc7da0404b07734ff5c7be4bdee4037e53.tar.bz2
Protect against faulty configuration settings a tad better.
CVS patchset: 3613 CVS date: 2002/12/21 16:25:31
-rw-r--r--src/xine-engine/configfile.c9
1 files 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;
}