diff options
author | grog <grog@FreeBSD.org> | 2009-03-13 03:51:41 +0000 |
---|---|---|
committer | grog <grog@FreeBSD.org> | 2009-03-13 03:51:41 +0000 |
commit | 5e19c4ab439a8851aab86b55404a7fca7ddefe9a (patch) | |
tree | 2bc062bdc7b9f10797b66bf36364ba6c24e81d26 /usr.sbin/sysinstall/config.c | |
parent | 6204638785a09f1228eacedc7ac5e8fe6a4fc377 (diff) | |
download | FreeBSD-src-5e19c4ab439a8851aab86b55404a7fca7ddefe9a.zip FreeBSD-src-5e19c4ab439a8851aab86b55404a7fca7ddefe9a.tar.gz |
Add menus to read install.cfg from any disk device sysinstall can see
(eg USB key, CD) rather than just floppy.
Handle \r\n line termination in a cfg file.
Add keeprcconf variable.
Submitted by: Daniel O'Connor
Diffstat (limited to 'usr.sbin/sysinstall/config.c')
-rw-r--r-- | usr.sbin/sysinstall/config.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/usr.sbin/sysinstall/config.c b/usr.sbin/sysinstall/config.c index 7693833..ff4c1f9 100644 --- a/usr.sbin/sysinstall/config.c +++ b/usr.sbin/sysinstall/config.c @@ -428,8 +428,12 @@ configRC_conf(void) while(fgets(line, sizeof(line), rcOld)) { if(line[0] == '#' || variable_check2(line) != 0) fprintf(rcSite, "%s", line); - else - fprintf(rcSite, "#REMOVED: %s", line); + else { + if (variable_get(VAR_KEEPRCCONF) != NULL) + fprintf(rcSite, "%s", line); + else + fprintf(rcSite, "#REMOVED: %s", line); + } } fclose(rcOld); } else if (write_header) { |