freebsd-skq/sbin
Bruce Evans cc52d04f9f Guard against a block size of 0 in the label. When the first
superblock is invalid, fsck looks at the label to help guess where
the next superblock should be.  If the partition type is 4.2BSD,
fsck assumed that the block size was valid and divided by it, so
it dumped core if the size was 0.

Initialization of the label was broken almost 3 years ago in rev.1.9
of newfs/newfs.c.  Newfs does not change the label at all, so there
is no problem (except the breakage of the automatic search for
backup superblocks) unless something else sets the partition type
to 4.2BSD.  However, it is too easy to set partition types to
4.2.BSD by copying an old label or by using a disktab entry to
create the label.

PR:	2537
1998-01-19 16:28:29 +00:00
..
adjkerntz Add Id, add usage function. 1997-06-10 11:01:13 +00:00
badsect Remove Xref to format(8) which does not exist. 1997-10-15 17:33:47 +00:00
bsdlabel Die and stay dead. Ya got it?! 1997-07-04 01:30:09 +00:00
ccdconfig Properly drop group privs to open file names specified by the user. 1997-12-30 05:13:21 +00:00
clri Import Lite2's src/sbin, except for XNSrouted and routed. All relevant 1997-07-02 00:25:26 +00:00
comcontrol Revert $FreeBSD$ to $Id$ 1997-02-22 14:40:44 +00:00
cxconfig Show the real revision date and not the date that this 1997-06-23 04:03:49 +00:00
disklabel Die and stay dead. Ya got it?! 1997-07-04 01:30:09 +00:00
dmesg compare return value from getopt against -1 rather than EOF, per the final 1997-03-29 03:33:12 +00:00
dset Many places in the code NULL is used in integer context, where 1997-09-18 14:08:40 +00:00
dump The default dumplevel is 0. 1998-01-03 20:26:15 +00:00
dumpfs Print fs_maxfilesize. 1997-06-29 20:59:03 +00:00
dumplfs add Id line (so that the commit on RELENG_2_2 will have it too) 1997-08-25 12:50:01 +00:00
dumpon compare return value from getopt against -1 rather than EOF, per the final 1997-03-29 03:33:12 +00:00
fdisk Number partitions 1-4, not 0-3. 1997-06-03 21:24:39 +00:00
fsck Guard against a block size of 0 in the label. When the first 1998-01-19 16:28:29 +00:00
fsck_ffs Guard against a block size of 0 in the label. When the first 1998-01-19 16:28:29 +00:00
fsck_ifs Guard against a block size of 0 in the label. When the first 1998-01-19 16:28:29 +00:00
fsdb Remove __progname. Make -f a no-op flag as stated in the man page. Remove 1997-06-11 07:13:30 +00:00
fsirand Typo fix. 1997-06-16 06:54:30 +00:00
i386 Fixed some FUD (don't blame current msdosfs for old msdosfs+vfs_bio bugs). 1997-12-19 23:03:00 +00:00
ifconfig Removed most unused includes of <net/if_var.h> outside the kernel. 1998-01-16 17:38:56 +00:00
init This has always bugged me. At single user, the implied example it gives 1997-10-10 12:14:48 +00:00
ipfw Bump up packet and byte counters to 64-bit unsigned ints. As a 1998-01-08 03:03:54 +00:00
kldload Add -v in usage string. Add rcsid. 1998-01-05 07:07:44 +00:00
kldstat Sync. usage string and synopsis. Add rcsid. 1998-01-05 07:10:42 +00:00
kldunload Sync. usage string and synopsis. Add rcsid. 1998-01-05 07:10:42 +00:00
ldconfig Removed /etc/ld.so.conf reference from FILES section (people get 1998-01-01 02:31:47 +00:00
md5 Fix a few style nits from previous commit. 1997-12-29 14:05:49 +00:00
mknod Use err(3). 1997-06-16 06:35:23 +00:00
modload Enable simultaneous use of -u and -p options. Release any resources before 1997-08-21 22:33:59 +00:00
modunload compare return value from getopt against -1 rather than EOF, per the final 1997-03-29 03:33:12 +00:00
mount Add mount_devfs(8) to the SEE ALSO section. 1997-12-01 00:44:16 +00:00
mount_cd9660 Add missing .Ar. 1997-12-29 07:03:46 +00:00
mount_ext2fs Show the real revision date and not the date that this 1997-06-23 04:03:49 +00:00
mount_ifs Add mount_devfs(8) to the SEE ALSO section. 1997-12-01 00:44:16 +00:00
mount_lfs Show the real revision date and not the date that this 1997-06-23 04:03:49 +00:00
mount_msdos Fixed some FUD (don't blame current msdosfs for old msdosfs+vfs_bio bugs). 1997-12-19 23:03:00 +00:00
mount_msdosfs Fixed some FUD (don't blame current msdosfs for old msdosfs+vfs_bio bugs). 1997-12-19 23:03:00 +00:00
mount_nfs style(9) corrections 1997-12-26 23:28:17 +00:00
mount_null Use realpath on the source as well as the destination. 1997-05-23 17:07:40 +00:00
mount_nullfs Use realpath on the source as well as the destination. 1997-05-23 17:07:40 +00:00
mount_portal change s_port to ntohs(s_port) for printf in DEBUG. 1998-01-11 06:03:35 +00:00
mount_portalfs change s_port to ntohs(s_port) for printf in DEBUG. 1998-01-11 06:03:35 +00:00
mount_std compare return value from getopt against -1 rather than EOF, per the final 1997-03-29 03:33:12 +00:00
mount_umap Show the real revision date and not the date that this 1997-06-23 04:03:49 +00:00
mount_umapfs Show the real revision date and not the date that this 1997-06-23 04:03:49 +00:00
mount_union Fixed an example. 1997-08-25 21:17:38 +00:00
mount_unionfs Fixed an example. 1997-08-25 21:17:38 +00:00
mountd Oops..The default behaviour should be *not* to log all succeeded 1997-12-13 19:50:14 +00:00
natd Added copyright (taken from natd.c). 1997-12-30 00:38:56 +00:00
newfs Fixed some spelling errors. 1998-01-16 06:31:23 +00:00
newlfs compare return value from getopt against -1 rather than EOF, per the final 1997-03-29 03:33:12 +00:00
nextboot Spelling police. 1997-04-23 04:46:38 +00:00
nfsd Fix two missing arguments detected by "-Wformat". 1997-11-18 03:14:53 +00:00
nfsiod Fix missing arguments detected by "-Wformat". 1997-11-18 03:22:08 +00:00
nologin An odd merge from 2.2 to -current. Somehow that 2.2 nologin.5 1997-03-03 06:47:27 +00:00
ping Minor style nit noticed by bde. 1997-12-24 00:59:02 +00:00
quotacheck Remove lines inside #ifdef 0/#endif. 1997-06-30 11:10:18 +00:00
reboot Document recent changes (config files and -D...) and not so recent changes 1997-07-05 02:02:02 +00:00
restore Typo fix in the message displayed. 1997-12-21 15:40:11 +00:00
route style(9) corrections 1997-12-26 23:28:17 +00:00
routed Use err(3). Change exit(-1). Remove unused #include. 1998-01-14 07:17:12 +00:00
savecore Import Lite2's src/sbin, except for XNSrouted and routed. All relevant 1997-07-02 00:25:26 +00:00
scsi Use err(3). Change exit(-1), and make exit values equal to 1 when errors. 1998-01-12 07:57:57 +00:00
scsiformat kill the undead 1997-07-13 14:26:00 +00:00
shutdown Pass an actual empty environment to execle() as per POSIX rather than 1998-01-10 20:11:06 +00:00
slattach Remove unused private include files from slattach. 1997-12-21 13:42:27 +00:00
spppcontrol Remove more unused #includes. 1998-01-07 07:55:26 +00:00
startslip Remove unused include files 1997-12-22 13:46:08 +00:00
swapon .Xr vnconfig 8. This was suggested by Dworkin Muller <dworkin@village.org> 1997-08-26 00:32:06 +00:00
sysctl Install sysctl in /sbin. It is used in some cases in network_pass1(), 1997-12-18 15:34:08 +00:00
tunefs Import Lite2's src/sbin, except for XNSrouted and routed. All relevant 1997-07-02 00:25:26 +00:00
umount style(9) corrections 1997-12-26 23:28:17 +00:00
Makefile activate the programs that will be used to manipulate kld modules 1997-10-19 11:15:45 +00:00
Makefile.inc Part one of a "fix-and-move". Init(8) had make macros declared here 1997-02-10 17:41:33 +00:00