This fixes being unable to deselect subitems (options not affected) of modules, in make gconfig. Please include a little credit line in the Changelog if you accept it. It has been verified to work. The patch was taken against the currently latest available sources, 2.6.6-rc1.
--- linux-2.6.6-rc1/scripts/kconfig/gconf.c 2004-04-15 03:36:00.000000000 +0200 +++ linux/scripts/kconfig/gconf.c 2004-04-18 22:56:38.926945704 +0200 @@ -954,15 +954,30 @@ } } +tristate sym_get_next_val(struct menu *menu) +{ + if (menu->parent->sym && sym_get_tristate_value(menu->parent->sym) == mod) { + switch (sym_get_tristate_value(menu->sym)) { + case no: + return mod; + case mod: + return no; + default: + return yes; + } + } + + return (sym_get_tristate_value(menu->sym) + 1) % 3; +} + static void toggle_sym_value(struct menu *menu) { - const tristate next_val[3] = { no, mod, yes }; tristate newval; if (!menu->sym) return; - newval = next_val[(sym_get_tristate_value(menu->sym) + 1) % 3]; + newval = sym_get_next_val(menu); if (!sym_tristate_within_range(menu->sym, newval)) newval = yes; sym_set_tristate_value(menu->sym, newval); ------- Martin Persenius http://www.pmfp.net "I consider it no sacrifice to die for my country. In my mind, we came here to thank God that men like these have lived rather than to regret that they have died." -General George S. Patton Jr. ------------------------------------------------------- This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click _______________________________________________ kbuild-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/kbuild-devel