summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
authorJens Arnold <amiconn@rockbox.org>2008-02-23 10:17:31 +0000
committerJens Arnold <amiconn@rockbox.org>2008-02-23 10:17:31 +0000
commitdb70f8d20b7f2a7056c94ea9a77ea24ee62fb154 (patch)
treeb00648616181a8f35e1b2c4389cefe2d40a5b017 /apps
parenta32de4f25fc96bcd6da81579a57925f1fc832080 (diff)
downloadrockbox-db70f8d20b7f2a7056c94ea9a77ea24ee62fb154.tar.gz
rockbox-db70f8d20b7f2a7056c94ea9a77ea24ee62fb154.zip
Save empty filename settings when necessary. Fixes the inability to save the 'no backdrop' setting due to the new default.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16384 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r--apps/settings.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/apps/settings.c b/apps/settings.c
index a77af6fc44..5bbdcb1784 100644
--- a/apps/settings.c
+++ b/apps/settings.c
@@ -524,9 +524,8 @@ static bool settings_write_config(char* filename, int options)
524 break; 524 break;
525 case F_T_CHARPTR: 525 case F_T_CHARPTR:
526 case F_T_UCHARPTR: 526 case F_T_UCHARPTR:
527 if (((char*)settings[i].setting)[0] == '\0') 527 if (((char*)settings[i].setting)[0]
528 break; 528 && settings[i].filename_setting->prefix)
529 if (settings[i].filename_setting->prefix)
530 { 529 {
531 snprintf(value,MAX_PATH,"%s%s%s", 530 snprintf(value,MAX_PATH,"%s%s%s",
532 settings[i].filename_setting->prefix, 531 settings[i].filename_setting->prefix,
@@ -537,8 +536,7 @@ static bool settings_write_config(char* filename, int options)
537 settings[i].filename_setting->max_len); 536 settings[i].filename_setting->max_len);
538 break; 537 break;
539 } /* switch () */ 538 } /* switch () */
540 if (value[0]) 539 fdprintf(fd,"%s: %s\r\n",settings[i].cfg_name,value);
541 fdprintf(fd,"%s: %s\r\n",settings[i].cfg_name,value);
542 } /* for(...) */ 540 } /* for(...) */
543 close(fd); 541 close(fd);
544#if CONFIG_TUNER 542#if CONFIG_TUNER