Commit 839e4302 authored by Roman Zippel's avatar Roman Zippel Committed by Linus Torvalds

[PATCH] generate an error if writing of kernel config failed

generate an error if writing of kernel config failed
parent f6fb237b
...@@ -575,6 +575,9 @@ int main(int ac, char **av) ...@@ -575,6 +575,9 @@ int main(int ac, char **av)
conf_cnt = 0; conf_cnt = 0;
check_conf(&rootmenu); check_conf(&rootmenu);
} while (conf_cnt); } while (conf_cnt);
conf_write(NULL); if (conf_write(NULL)) {
fprintf(stderr, "\n*** Error during writing of the kernel configuration.\n\n");
return 1;
}
return 0; return 0;
} }
...@@ -785,15 +785,23 @@ int main(int ac, char **av) ...@@ -785,15 +785,23 @@ int main(int ac, char **av)
} while (stat < 0); } while (stat < 0);
if (stat == 0) { if (stat == 0) {
conf_write(NULL); if (conf_write(NULL)) {
fprintf(stderr, "\n\n"
"Error during writing of the kernel configuration.\n"
"Your kernel configuration changes were NOT saved."
"\n\n");
return 1;
}
printf("\n\n" printf("\n\n"
"*** End of Linux kernel configuration.\n" "*** End of Linux kernel configuration.\n"
"*** Execute 'make' to build the kernel or try 'make help'." "*** Execute 'make' to build the kernel or try 'make help'."
"\n\n"); "\n\n");
} else } else {
printf("\n\n" fprintf(stderr, "\n\n"
"Your kernel configuration changes were NOT saved." "Your kernel configuration changes were NOT saved."
"\n\n"); "\n\n");
return 1;
}
return 0; return 0;
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment