summaryrefslogtreecommitdiff
path: root/package/config/confdata.c
diff options
context:
space:
mode:
authorPeter Korsgaard <jacmet@sunsite.dk>2011-02-02 10:39:48 +0100
committerPeter Korsgaard <jacmet@sunsite.dk>2011-02-02 15:54:33 +0100
commit359a922659c6b33c44ab7c4f94de7d801a8bea63 (patch)
treed56ad42cbe74fb823bb1876cd0437507b5977712 /package/config/confdata.c
parenta7306b8aa5b51f7c6e9f5327e0bd80c11cfadda6 (diff)
package/config: Rebase against Linux 2.6.36
No significant changes, but makes it easier to rebase against newer versions. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Diffstat (limited to 'package/config/confdata.c')
-rw-r--r--package/config/confdata.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/package/config/confdata.c b/package/config/confdata.c
index 1b1fdb7b9..6455dc2fb 100644
--- a/package/config/confdata.c
+++ b/package/config/confdata.c
@@ -492,7 +492,9 @@ int conf_write_defconfig(const char *filename)
/*
* If symbol is a choice value and equals to the
* default for a choice - skip.
- * But only if value is bool and equal to "y" .
+ * But only if value is bool and equal to "y" and
+ * choice is not "optional".
+ * (If choice is "optional" then all values can be "n")
*/
if (sym_is_choice_value(sym)) {
struct symbol *cs;
@@ -500,7 +502,7 @@ int conf_write_defconfig(const char *filename)
cs = prop_get_symbol(sym_get_choice_prop(sym));
ds = sym_choice_default(cs);
- if (sym == ds) {
+ if (!sym_is_optional(cs) && sym == ds) {
if ((sym->type == S_BOOLEAN) &&
sym_get_tristate_value(sym) == yes)
goto next_menu;