Commit Graph

4064 Commits

Author SHA1 Message Date
pjd
38bd67169d Fixed some non-critical memory leaks and one temporary file leak
(theoretical).

Approved by:	phk, scottl (mentor)
2004-02-05 08:39:38 +00:00
bde
11c7633086 Document the dirty flag and other bits in the first 2 FAT entries
better.  There is a related I/O error flag which we don't support in
the kernel but must support here.  (Support for bits that we don't
understand here is mostly automatic by fail-safeness, but checkdirty()
has fail-unsafeness.)  There are some reserved and don't-care bits
that weren't fully documented and aren't always masked properly.  The
comment about the bits in readfat() will be removed when the masking
is fixed.

Submitted by:	rnordier
2004-02-05 06:55:12 +00:00
bde
12c02b35e9 Prepare to fix checkdirty() by moving it from check.c to fat.c. It is
identical to a subset of readfat(), so it belongs near readfat() if not
in it.
2004-02-05 06:32:16 +00:00
brooks
b8d51aa138 Add ifconfig support for network interface renaming. In the process,
reorganize the printing of the interface name when using wildcard
cloning so it is not printed if it we either immediately rename or
destroy the interface.

Reviewed by:	ru
2004-02-04 02:55:46 +00:00
des
69ab9ceec0 Mechanical whitespace cleanup. Also, note that previous commit was
Sponsored by:	Teleplan AS
2004-02-03 11:12:29 +00:00
des
bd77f8c94f Remove newline characters from error strings. 2004-02-03 11:10:34 +00:00
nectar
39de947ca8 Correct a typo and unbreak the build.
Pointy hat to:	pjd
2004-02-03 04:03:19 +00:00
pjd
9354393ea0 Made use of MNT_USER flag and inform about user responsible for mount
in those cases:
1. File system was mounted by an unprivileged user.
2. File system was mounted by an unprivileged root user.
3. File system was mounted by a privileged non-root user.

Point 1 is when file system was mounted by unprivileged user
(sysctl vfs.usermount was equal to 1 then).

Point 2 is when file system was mounted by root, while sysctl
security.bsd.suser_enabled is set to 0 and sysctl vfs.usermount
is set to 1.

Point 3 is because we want to be ready for capabilities.

Reviewed by:	rwatson
Approved by:	scottl (mentor)
2004-02-02 18:37:30 +00:00
ceri
793b22a99c Spell "disklabel" correctly.
Approved by:	ru
2004-02-01 13:09:26 +00:00
brooks
ee34d661df Use memcpy plus a manual NUL termination when copying the interface name
from the sdl because strlcpy requires that the source string be
NUL-terminated unlike strncpy.

Submitted by:	Peter Jeremy <PeterJeremy at optushome dot com dot au>
2004-01-31 22:59:03 +00:00
obrien
56844e70af Install a 'disklable' alias.
Technical Reviewed by:	ru
2004-01-31 07:39:45 +00:00
obrien
6707230215 Sync with bsdlabel/Makefile. 2004-01-29 18:15:19 +00:00
obrien
e8f03f143e Add a very basic manpage. 2004-01-29 18:12:27 +00:00
guido
27e023aa19 Style(9) option sorting
Submitted by:	Ruslan Ermilov <ru@FreeBSD.org>
2004-01-29 15:14:03 +00:00
guido
a5eee69dd6 Fix manpage and usage() to reflect that -a can be used in combination
with -o

Submitted by:	Ruslan Ermilov <ru@FreeBSD.org>
Pointed out by: Ceri Davies <ceri@submonkey.net
2004-01-29 14:42:26 +00:00
ru
e3539b3617 Removed duplicate $FreeBSD$ tag. 2004-01-29 14:36:16 +00:00
guido
5133532cb7 Unbreak -o fstab and -o current in combination with -a
MFC after:	2 weeks
2004-01-29 13:16:51 +00:00
obrien
b329bb8a2c This has been disconnected from the build since May 2003. GC it, as
bsdlabel and sunlabel are what we use now.
2004-01-28 19:29:16 +00:00
des
cf221c4c0d Style nit in previous commit. 2004-01-27 19:28:13 +00:00
mckusick
38230899d9 Preserve acls option on mounts when taking a snapshot.
Submitted by:	Wiktor Niesiobedzki <freebsd-lists@w.evip.pl>
2004-01-27 18:28:11 +00:00
brooks
280fcfee01 Use IFNAMSIZ instead of a magic value for the length of an interface
name.

Prevent the kernel from potentially overflowing the interface name
variable.  The size argument of strlcpy is complex because the name is
not null-terminated in sdl_data.
2004-01-27 01:43:14 +00:00
cperciva
3a15ac7b11 Avoid dereferencing null pointers in fsck_ffs. (pfatal may return,
so it isn't a safe way of handling [mc]alloc failures.)

PR:		misc/61800
Approved by:	rwatson (mentor)
2004-01-26 15:05:30 +00:00
harti
5ab2525e7f Add support for virtual interfaces. These have no phy chip and, hence, we
need to handle interfaces without phy specially.
2004-01-26 12:17:49 +00:00
maxim
ed6eaf7bd9 o Pass a correct argument to errx(3).
PR:		bin/61846
Submitted by:	Eugene Grosbein
MFC after:	1 week
2004-01-24 19:20:09 +00:00
blackend
d0bcb20ae1 Fix bogus "ffsinfo -c 0" example with "ffsinfo -g 0 -l 4".
PR:		bin/61472
Submitted by:	Alex Popa <razor@ldc.ro>
MFC after:	1 week
2004-01-23 17:35:09 +00:00
mtm
2ee2805e83 grammar 2004-01-23 06:37:19 +00:00
cperciva
7fd2e87e6c Clarify behaviour of ffsinfo: It appends to outfile without
removing any existing contents.

PR:		bin/61473
Submitted by:	Alex Popa <razon@ldc.ro>
MFC after:	7 days
Approved by:	rwatson (mentor)
2004-01-23 05:13:22 +00:00
grehan
2dafdd4f00 Userland signed char fixes for PPC build. Problems were using a char
return for getopt() and comparing to -1, ditto with fgetc() and EOF,
and using the kg_nice value from <sys/user.h>

Submitted by: Stefan Farfeleder <stefan@fafoe.narf.at>
Reviewed by: obrien, bde (a while back)
Tested lightly on: ppc, i386, make universe
2004-01-22 07:23:36 +00:00
sos
7b3d7d7361 Cosmetics 2004-01-21 21:31:19 +00:00
ru
ca1efbafd6 Mark this manpage as i386-only. 2004-01-21 13:24:38 +00:00
ru
942c095e46 Fixed spacing in previous revision. 2004-01-17 00:31:38 +00:00
ru
6593bb80ea - Build things in pure dictionary order (see sort(1)).
- Unify the conditional assignments section so that architectural
  exclusions come first, then options and !options, sorted by the
  option name, also in directory order, then architecture specific
  sections, sorted by the architecture name, with i386 being a
  traditional exception.

Prodded by:	bde
2004-01-16 15:23:19 +00:00
sam
10ba1b2264 802.11 mode bits are now masks; convert to suit 2004-01-15 15:19:19 +00:00
maxim
d675b0ba7c o -c (compact) flag is ipfw2 feature.
PR:		bin/56328
MFC after:	3 days
2004-01-15 12:59:44 +00:00
maxim
36a468e048 o -f (force) in conjunction with -p (preprocessor) is ipfw2 feature.
MFC after:	3 days
2004-01-15 12:57:04 +00:00
alex
f1fc1fb354 Add RSH to the list of enviroment variables. 2004-01-15 12:13:54 +00:00
ume
ff9ef7b641 -DSMALL will remove the need of dump.c (for rtsol)
Obtained from:	KAME
2004-01-14 17:59:38 +00:00
phk
39966fbafe Note that geometry can also be specified on vnode backed deviecs. 2004-01-12 10:54:09 +00:00
nyan
e535657797 '-DPC98' is not needed. 2004-01-11 09:11:10 +00:00
simon
0cae6b4312 Add manual page links from fsck_ufs.8 and fsck_4.2bsd.8 to fsck_ffs.8,
since there are already the same links for the program binary.

Suggested by:	mat
2004-01-10 14:36:49 +00:00
ceri
91077cabf9 Correct an instance of an erroneous "it's".
PR:		docs/59937
Submitted by:	Ada Lim <ada@bsd.org>
MFC After:	1 day
2004-01-07 23:31:22 +00:00
anholt
7cdd2d8812 Allow trailing slashes for MNT_UPDATE case (mount -u), too.
PR:		bin/59144
Submitted by:	Stefan Farfeleder <stefan@fafoe.narf.at>
2004-01-07 05:37:56 +00:00
alfred
fbfb1488fd Hook mount_nfs4 to the build.
Noticed by: rwatson
2004-01-06 21:05:13 +00:00
iedowse
6fde69b7d1 Define _PATH_MKSNAP_FFS and use it in dump(8) instead of assuming
that mksnap_ffs(8) can be found using the current $PATH.

Reviewed by:	mckusick
2004-01-04 17:17:46 +00:00
phk
880a2ed129 Warn that big malloc disks are a panic(8) implementation.
Submitted by:	Colin Percival <cperciva@builder.daemonology.net>
(Who should really get his own bit one of these days!)

PR:	59988
2004-01-02 14:28:06 +00:00
alfred
d82d9c329c Document that mknod(8) can be used to undelete entries under devfs. 2003-12-29 00:37:52 +00:00
bde
20ebc42a34 Oops, highly non-KNF indentation is normal for large expressions in
this program.  Gnu indentation is used for these.  Redo the fix for
the large expression at the end of the previous commit to give gnu
indentation.  The original version was gnuish but had 9 bogus extra
characters of indentation in its continuation lines, perfect tab
lossage on every line, and other bugs.

The previous commit log should have claimed to fix style bugs in the
previous-1 commit (1.5), not the forced null previous commit (1.6).
2003-12-28 01:30:31 +00:00
bde
10a5b874bb Expanded the comment about the -F flag.
Fixed a nearby style bug (unreachable break).
2003-12-27 14:02:52 +00:00
bde
890b93648b Use __printflike() and __dead2 instead of hard-coded gccisms.
Declare perror().  We define and use a home made version of perror(3)
that can't simply be removed (although it has the same interface as
perror(3)) since it is very different (it prints on stdout, doesn't
always print the program name, and sometimes exits).  Declare it to
get a reminder of this brokenness when WARNS is increased enough.
2003-12-27 13:54:02 +00:00
bde
e73943dcf6 Garbage-collected hotroot, rawname() and unrawname() again. These
became garbage when block devices were axed and were removed a few
months later, but they came back (with hotroot renamed to hot + hotroot())
when the NetBSD fsck was mismerged.
2003-12-27 13:29:49 +00:00