Commit Graph

43 Commits

Author SHA1 Message Date
David E. O'Brien
1ff2ab846d Better to just statically set the name vs. determine at run time. 2008-05-11 17:23:57 +00:00
David E. O'Brien
228a522072 Clean up several instances of SADE calling itself sysinstall.
(do so generically so the same set of changes can be applied to sysinstall)
2008-05-11 07:13:08 +00:00
Sean Farley
2966d28c32 Significantly reduce the memory leak as noted in BUGS section for
setenv(3) by tracking the size of the memory allocated instead of using
strlen() on the current value.

Convert all calls to POSIX from historic BSD API:
 - unsetenv returns an int.
 - putenv takes a char * instead of const char *.
 - putenv no longer makes a copy of the input string.
 - errno is set appropriately for POSIX.  Exceptions involve bad environ
   variable and internal initialization code.  These both set errno to
   EFAULT.

Several patches to base utilities to handle the POSIX changes from
Andrey Chernov's previous commit.  A few I re-wrote to use setenv()
instead of putenv().

New regression module for tools/regression/environ to test these
functions.  It also can be used to test the performance.

Bump __FreeBSD_version to 700050 due to API change.

PR:		kern/99826
Approved by:	wes
Approved by:	re (kensmith)
2007-07-04 00:00:41 +00:00
Andrey A. Chernov
ba174a5e38 Back out all POSIXified *env() changes.
Not because I admit they are technically wrong and not because of bug
reports (I receive nothing). But because I surprisingly meets so
strong opposition and resistance so lost any desire to continue that.

Anyone who interested in POSIX can dig out what changes and how
through cvs diffs.
2007-05-01 16:02:44 +00:00
Andrey A. Chernov
322627150d Prepare for upcoming POSIXed putenv() rewrite:
don't allow putenv() arg be on the stack, use strdup()
2007-04-30 13:07:33 +00:00
Alexander Leidinger
2e14ff0f41 Say welcome to 'sade', the SysAdmins Disk Editor. It's the fdisk and disklabel part
of sysinstall. So sysinstall may retire now, we have the important non-install part
of it covered.

ATM it doesn't understand GEOM stuff (like mirror, stripe, raid, ...), but patches
to change this and to clean it up internally are more than welcome.

Submitted by:	mami@nyitolap.hu
2006-08-07 23:35:49 +00:00
Bruce Evans
03f0d9e8ae Fixed assorted misuses of NULL in integer context. 2004-03-11 11:58:16 +00:00
Tom Rhodes
b9c3c3fc77 Give users the ability to select an alternative MTA during the installation.
This option adds Postfix and Exim to the list, however, qmail is not added
due to license restrictions.

Collaborated with:	Simon L. Nielsen <simon@nitro.dk>
Reviewed by:		jhb, re@, -audit.
2003-07-12 15:33:09 +00:00
Jun Kuriyama
b46e66a5a5 debugMsg() should end with "\n". 2002-11-01 02:05:05 +00:00
Murray Stokely
a0769a8d73 Add a couple of functions to create persistent variables that will
survive a sysinstall Ctrl-C -> 'Restart'.  This fixes another annoying
bug where restarting sysinstall will try to reload kernel modules and
do other external things that have already been done.  For now, use
these persistent variables to keep track of module, usbd, and pccardd
initialization.

Bug found by: rwatson
MFC after:    1 week
2001-09-24 10:16:23 +00:00
Murray Stokely
eba8393e91 Add a function to free all of sysinstall's internal variables from the
environment.  This fixes an annoying bug where hitting Ctrl-C and
telling sysinstall to 'restart' will do no such thing since many of
the options are still set and so you won't be prompted for them
again.

MFC after:	1 week
2001-09-22 18:10:56 +00:00
Kris Kennaway
a015c9348c Mark relevant functions __printflike()/__printf0like() and silence some of
the non-constant format string warnings.

MFC after:	1 week
2001-07-05 09:51:09 +00:00
Jordan K. Hubbard
99f9320ef7 Fix the HTTP transfer code to correctly parse the port number if
specified.

Submitted by:	pho
2000-07-30 22:18:53 +00:00
Jordan K. Hubbard
2150746365 Clean up some of the abstraction in this code. 2000-02-26 11:57:22 +00:00
Jordan K. Hubbard
3910e95363 Oh crud, did I ever screw the pooch! Rather than sync this with -stable,
I backed-out the changes in -current and didn't touch stable at all (I
thought I had my patch order reversed, not what actually happened).
AIEEE!  I can't even blame the crack for this one since I broke my
crack pipe a few weeks ago.  I think sleep deprivation gets the blame
for this one.

Medal for noticing this one goes to:	Jim Bloom <bloom@acm.org>
1999-09-02 00:51:16 +00:00
Jordan K. Hubbard
d03dcaa779 MFC: Catch 3.2-stable sysinstall up to 4.0-current level functionality,
bringing in DHCP support.  The only thing I left out were Poul-Henning's
newfs changes since I'm not sure if he's brought the rest of that support
into -stable yet.  If it turns out that this is the case, I'll MFC those
changes too.
1999-09-01 04:29:30 +00:00
Peter Wemm
97d92980a9 $Id$ -> $FreeBSD$ 1999-08-28 01:35:59 +00:00
Jordan K. Hubbard
605c88e44b Re-enable DHCP client support again (but optional and turned off by default
for the time being) for debugging purposes.

Fix bug in options selection.
1999-07-16 11:13:09 +00:00
Jordan K. Hubbard
63cad5499d Totally change the way variables are accounted for in sysinstall.
Now we know which variables are internal and which need to be
backed to /etc/rc.conf.site.  rc.conf is not touched now.

Also kget kernel change information back properly and set up a loader.rc
file to use it.
1999-02-05 22:15:52 +00:00
Jordan K. Hubbard
8eac04a792 MF22: Paul Traina's changes. 1998-07-18 09:42:02 +00:00
Jordan K. Hubbard
09b58bbc77 Reformatting, more sanity checks. 1998-03-15 17:10:17 +00:00
Jordan K. Hubbard
1a8a1188c0 Correct misfeature with quoting, better error reporting. 1998-03-10 17:24:08 +00:00
Jordan K. Hubbard
b09dc169b7 Separate the siamese twins that were the partition and label editor.
Now you can use one without entering the other and it will DTRT.
These changes just allowed me to do the most straight-forward new disk
installation I've ever managed with sysinstall.
1997-10-12 16:21:21 +00:00
Jordan K. Hubbard
08e6881746 YAMF22 1997-06-13 14:21:22 +00:00
Jordan K. Hubbard
ba40d0fede YAMF22 - Bugs Of Evil in variable handling and rc.conf editing.
PR#: 3218 [partial]
1997-06-11 08:41:10 +00:00
Jordan K. Hubbard
8e45ec2c8c Resurrect / implement some of the more esoteric scripting features,
such as partitioning a disk or overriding an interactive prompt.
1997-06-05 09:48:03 +00:00
Peter Wemm
b97fa2ef50 Revert $FreeBSD$ to $Id$ 1997-02-22 14:13:04 +00:00
Jordan K. Hubbard
2bd4114e2a Minor cleanup, adjust for latest version of apache web server. 1997-01-16 10:48:00 +00:00
Jordan K. Hubbard
37c16c5340 Clean up a long-standing bug in the scripting code. You could set variables,
but you couldn't call functions!  Now you can do both.
Guard against whitespace pollution in variable names.
1997-01-16 10:24:09 +00:00
Jordan K. Hubbard
1130b656e5 Make the long-awaited change from $Id$ to $FreeBSD$
This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore.  This update would have been
insane otherwise.
1997-01-14 07:20:47 +00:00
Jordan K. Hubbard
86767547be Be more efficient in how we use memory (stumbled across while looking for
something else) for attributes and variables.

Remove stack-stomper in sstrncpy().
1996-12-11 18:23:19 +00:00
Jordan K. Hubbard
00b69db338 As Paul has just pointed out, much of my strncpy() usage was either
bogus or overly complex and really needed to be done more consistently
and sanely throughout - no question about it.  Done.

Suggested-By: Paul Traina <pst@Shockwave.COM>
1996-12-09 08:22:19 +00:00
Jordan K. Hubbard
061e2fb9a6 Fix a truly stupid bug which broke the package installation menu
for everything _but_ the multi-user case now (it was the opposite before :-).
That means adding packages with the 2.2-960511-SNAP boot floppy is busted. Feh.
1996-06-12 14:02:13 +00:00
Jordan K. Hubbard
1966645d08 Add some more debugging statements. 1996-04-29 06:47:10 +00:00
Jordan K. Hubbard
2113a60c4b Bring this into sync.
I still have a _very very annoying_ display bug which occurs when a menu
item causes a submenu to be displayed - the screen repaints for the original
menu (which is restored upon return from the submenu) are off by about 4
characters.  I've tried restoring the screen, the cursor position, you name
it - same deal.  Grrrr!  This commit is my first step in trying to get someone
else to help me look into this one since I'm just tearing my hair out at this
point!
1996-04-23 01:29:35 +00:00
Jordan K. Hubbard
af4cbec4e1 1. Update all the copyrights to delete useless clauses 3 and 4.
2. Change more of the menu code over to new system.
3. Streamline label editor.
1996-04-13 13:32:15 +00:00
Peter Wemm
40b0c0d936 Update the -current sources from the 2.1 branch.
Approved (in spirit) by: jkh
1995-12-07 10:34:59 +00:00
Rodney W. Grimes
d3628763db Merge RELENG_2_0_5 into HEAD 1995-06-11 19:33:05 +00:00
Rodney W. Grimes
e5370bd7fe Remove trailing whitespace. 1995-05-30 08:29:07 +00:00
Jordan K. Hubbard
8e98d776c0 Commit parts of reorg that were diffs. Substantially re-engineer the
extraction and mediaGetFTP() handshaking to solve some unexpected complexities.
1995-05-27 10:47:44 +00:00
Jordan K. Hubbard
395dda4194 Clean up the variable handling code a little.
Write /etc/hosts in the right place.
1995-05-26 20:45:20 +00:00
Jordan K. Hubbard
f10eb488f6 1. Fix a pathological bug I introduced in msgInfo(). Right idea, wrong
implementation.

2. Totally rework device registration.  It's about half the size and
   more powerful now.

3. Add DOS discovery.

4. Start filling in some of the strategy routines.

5. Another clean-up pass over the menus.

6. Make wizard code use Disk typedef.

If I can get the first strategy routine finished tonite, we should have a working
install (from ftp, at least) this weekend.
1995-05-20 10:33:14 +00:00
Jordan K. Hubbard
411bac67a7 Commit my latest changes before having a nap. Still not close to done,
nor is it in sync with my working sources, but it leaves me less CVS hassles
to bring in the new files at this time.  Still no documentation to translate
quite yet, but soon.  This stuff is actually very close now.
1995-05-01 21:56:32 +00:00