Eitan Adler
50e04779c4
Check the return error of set[e][ug]id. While this can never fail in the
...
current version of FreeBSD, this isn't guarenteed by the API.
Custom security modules, or future implementations of the setuid and
setgid may fail.
Submitted by: Erik Cederstrand
Approved by: cperciva
MFC after: 3 days
2012-10-22 03:07:05 +00:00
Ed Schouten
1efe3c6b58
Add missing static keywords for global variables to tools in sbin/.
...
These tools declare global variables without using the static keyword,
even though their use is limited to a single C-file, or without placing
an extern declaration of them in the proper header file.
2011-11-04 13:36:02 +00:00
Ulrich Spörlein
3ba5db25bb
Remove dead variable assignments
...
Found by: clang static analyzer
Verified by: md5(1)
2010-06-11 17:03:04 +00:00
Martin Cracauer
3f4f4a1465
Make CCD be able to read and write Linux software raids.
...
Supported for raid-0 with <n> disks, raid-1 with 2 disks.
Manpages have examples, warnings etc.
Test scripts on
http://www.cons.org/cracauer/ccdconfig-linux/
Reviewed by: alfred
2006-04-13 20:35:31 +00:00
Stefan Farfeleder
d414fcbc3e
Garbage collect useless variables.
2005-08-05 07:39:39 +00:00
Ruslan Ermilov
8d646af581
Sync program's usage() with manpage's SYNOPSIS.
2005-02-10 09:19:34 +00:00
Johan Karlsson
7f1740e82a
Make this WARNS=6 clean by renaming the variable 'err' to 'error'
...
in order not to shadow err(3).
Tested by: make universe
2003-08-07 19:10:35 +00:00
Poul-Henning Kamp
98e7d61119
Be consistent about module names.
2003-06-09 21:50:41 +00:00
Poul-Henning Kamp
df622d54f8
GEOMification of CCD.
...
You need your kernel and ccdconfig(8) to be in sync, particularly if your
source tree is on a ccd device.
2003-06-09 19:25:07 +00:00
Poul-Henning Kamp
0f557e0ac0
Further devilification of CCD:
...
Change the list interface to simplify things.
Remove old list ioctls which bogusly exported the softc to userland.
Move the softc and associated structures from the public header to
the source file.
2003-06-02 21:29:04 +00:00
Poul-Henning Kamp
c06bf12f3b
Use GEOM OAM api to retrive list of configured ccd devices.
...
Link against libgeom.
2003-06-02 20:50:59 +00:00
David E. O'Brien
c69284ca08
Use __FBSDID() to quiet GCC 3.3 warnings.
2003-05-03 18:41:59 +00:00
Poul-Henning Kamp
a9f65dc3a8
Don't pick the name out of the devstat member of the ccd softc, it will
...
disappear soon. Exporting the softc in the first place is a mistake.
2003-03-06 06:31:49 +00:00
Poul-Henning Kamp
b02a19f2b7
Fix two errorchecks to check for negative error returns.
2003-01-18 10:29:24 +00:00
Poul-Henning Kamp
ddbf51af0c
Find places to store the previously implicityly passed unit number in
...
the three configuration ioctls which need a unit number.
Add a "ccd.ctl" device for config operations.
Implement ioctls on ccd.ctl which rely on the explicityly passed
unit numbers.
Update ccdconfig to use the new ccd.ctl interface.
Add code to the kernel to detect old ccdconfig binaries, and whine
about it.
Add code to ccdconfig to detect old kernels, and whine about it.
These two compatibility measures will be retained only for a limited
period since they are in the way of GEOM'ification of ccd.
2003-01-17 14:53:53 +00:00
Poul-Henning Kamp
22f2948816
Fix various details so we get to WARNS=3.
...
Center operation on unit number rather than path name.
2003-01-17 13:23:41 +00:00
Poul-Henning Kamp
fc6db1e23f
Remove CCDF_SWAP and CCDF_PARITY. They have never been implemented.
2003-01-03 08:56:54 +00:00
Warner Losh
e5fa3ee654
o __P removal.
...
o Use ANSI function definitions.
o main(int, char *[])
2002-03-18 05:00:52 +00:00
Ruslan Ermilov
5788dd0ee8
Removed -M and -N from getopt(3) call as well.
2001-09-11 09:49:36 +00:00
Poul-Henning Kamp
ae919cce4a
Duh! forgot this bit of the NCCD patch.
...
Submitted by: sobomax
Reviewed by: phk
2001-09-04 09:19:48 +00:00
Ruslan Ermilov
3b7e5ccc6a
SECURITY: Drop `setgid kmem' bit as early as possible.
2001-08-31 16:26:37 +00:00
David E. O'Brien
1a37aa566b
Add `_PATH_DEVZERO'.
...
Use _PATH_* where where possible.
2000-12-09 09:35:55 +00:00
Alexander Langer
b10a063dbe
Fix world-breakage: warnx("..') --> warnx("...")
...
Submitted by: Alain Thivillon <Alain.Thivillon@hsc.fr>,
Udo Erdelhoff <ue@nathan.ruhr.de>
Approved by: green
2000-08-05 15:45:59 +00:00
Kris Kennaway
d045f16001
Don't call warnx() without a format string (localized error messages
...
could conceivably cause a crash).
Obtained from: OpenBSD
2000-08-05 06:06:48 +00:00
Nick Hibma
3e2c6ca3b9
Removal of sys/device.h
...
- Move intrhook stuff into kernel.h
- Remove all occurrences of #device <device.h>
- Add kernel.h were necessary (nowhere)
- delete device.h
This file contained the structures for cfdata (old style config) and is no
longer used. It was included by most drivers.
It confuses the remote debugger as the definition of 'struct device' in
device.h is found before the one in bus_private.h.
1999-10-05 21:19:41 +00:00
Bill Fumerola
2ce3df4e05
Silence -Wall
...
Reviewed by: dillon
1999-09-26 21:37:46 +00:00
Peter Wemm
7f3dea244c
$Id$ -> $FreeBSD$
1999-08-28 00:22:10 +00:00
Bill Fumerola
9539436c36
(1) Include linker.h because we use kldload()
...
(2) Clear up an ambigious, nested if/else
(3) Cast a ccio_size to a long and use the correct format identifier.
Reviewed by: green
1999-07-04 23:42:32 +00:00
Poul-Henning Kamp
34fee57ad2
don't use <sys/disk.h>
1999-05-06 19:20:34 +00:00
Peter Wemm
769ae4addb
kldload("ccd") if the ccd module isn't present.
1999-04-05 06:30:12 +00:00
Justin T. Gibbs
b2dfb1f906
Update system to new device statistics code.
...
Submitted by: "Kenneth D. Merry" <ken@plutotech.com>
mike@smith.net.au (Mike Smith)
1998-09-15 08:15:30 +00:00
Philippe Charnier
9ad54eb7b3
Correct use of .Nm, use .Bl/.El in FILES section. Add rcsid. Remove unused
...
#includes and make it a little more -Wall-friendly.
1998-06-04 06:41:26 +00:00
Warner Losh
15678bfa03
Properly drop group privs to open file names specified by the user.
...
Submitted by: Niall Smart rotel@indigo.ie
Obtained from: OpenBSD (rev 1.7 and 1.8)
1997-12-30 05:13:21 +00:00
Philippe Charnier
86d025a068
Remove __progname. Cosmetic in usage string.
1997-06-10 11:04:50 +00:00
Peter Wemm
c0ec1f37ef
Revert $FreeBSD$ to $Id$
1997-02-22 14:40:44 +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
Satoshi Asami
15a2c56b61
Add mirror and parity flags to list of symbolic names.
1996-01-30 22:25:24 +00:00
Satoshi Asami
aa8bdaec2b
Added $Id$.
1995-12-28 00:22:45 +00:00
Satoshi Asami
602e098fc1
Make it work for FreeBSD-2.1.
1995-12-27 10:57:20 +00:00
Satoshi Asami
89a7b2b714
ccdcontrol from NetBSD-1.1. Note it was called "ccdconfig" originally.
1995-12-27 10:51:05 +00:00