kconfig/mconf.c
changeset 39 af42eec9d383
parent 1 eeea35fbf182
child 94 f32c4f663805
     1.1 --- a/kconfig/mconf.c	Sat Feb 24 11:00:05 2007 +0000
     1.2 +++ b/kconfig/mconf.c	Sun Apr 15 16:45:11 2007 +0000
     1.3 @@ -868,7 +868,7 @@
     1.4  	bindtextdomain(PACKAGE, LOCALEDIR);
     1.5  	textdomain(PACKAGE);
     1.6  
     1.7 -	conf_parse(av[1] ? av[1] : "");
     1.8 +	conf_parse(av[1]);
     1.9  	conf_read(NULL);
    1.10  
    1.11  	sym = sym_lookup("PROJECTVERSION", 0);
    1.12 @@ -890,26 +890,33 @@
    1.13  	do {
    1.14  		conf(&rootmenu);
    1.15  		dialog_clear();
    1.16 -		res = dialog_yesno(NULL,
    1.17 -				   _("Do you wish to save your "
    1.18 -				     "new "PROJECT_NAME" configuration?\n"
    1.19 -				     "<ESC><ESC> to continue."),
    1.20 -				   6, 60);
    1.21 +		if (conf_get_changed())
    1.22 +			res = dialog_yesno(NULL,
    1.23 +					   _("Do you wish to save your "
    1.24 +					     "new "PROJECT_NAME" configuration?\n"
    1.25 +					     "<ESC><ESC> to continue."),
    1.26 +					   6, 60);
    1.27 +		else
    1.28 +			res = -1;
    1.29  	} while (res == KEY_ESC);
    1.30  	end_dialog();
    1.31 -	if (res == 0) {
    1.32 +
    1.33 +	switch (res) {
    1.34 +	case 0:
    1.35  		if (conf_write(NULL)) {
    1.36  			fprintf(stderr, _("\n\n"
    1.37 -				"Error writing "PROJECT_NAME" configuration.\n"
    1.38 -				"Your configuration changes were NOT saved."
    1.39 +				"Error during writing of "PROJECT_NAME" configuration.\n"
    1.40 +				"Your kernel configuration changes were NOT saved."
    1.41  				"\n\n"));
    1.42  			return 1;
    1.43  		}
    1.44 +	case -1:
    1.45  		printf(_("\n\n"
    1.46  			"*** End of "PROJECT_NAME" configuration.\n"
    1.47 -			"*** Execute 'make' to build, or try 'make help'."
    1.48 +			"*** Execute 'make' to build the kernel or try 'make help'."
    1.49  			"\n\n"));
    1.50 -	} else {
    1.51 +		break;
    1.52 +	default:
    1.53  		fprintf(stderr, _("\n\n"
    1.54  			"Your configuration changes were NOT saved."
    1.55  			"\n\n"));