Commit Graph

12595 Commits

Author SHA1 Message Date
Jung-uk Kim
07e547fe26 Add a new build option, MAN_UTILS. This option lets you control building
utilities and related support files for manual pages, which were previously
controlled by MAN.  For POLA, the default depends on MAN, i.e., WITHOUT_MAN
implies WITHOUT_MAN_UTILS and WITH_MAN implies WITH_MAN_UTILS.  This patch
is slightly improved by me from:

PR:		misc/145212
2010-05-19 23:56:26 +00:00
Ulrich Spörlein
62486687ed mdoc: consistently spell our email addresses <foo@FreeBSD.org>
Reviewed by:	ru
2010-05-19 08:57:53 +00:00
Ulrich Spörlein
e7b5f4d907 Garbage collect unused variable, missed in r200840
Found by:	clang static analyzer
2010-05-19 08:52:59 +00:00
Ulrich Spörlein
cd0788e137 - Fix terminating argument to execl(3), sizeof(NULL) != sizeof(char *)
might be true on some systems [1]
- Rewrite gotos to use return directly
- Some spelling fixes
- Reduce unneeded/non-standard Makefile settings

Requested by:			bde, imp [1]
Explanation provided by:	bde [1]
Reviewed by:			imp
2010-05-19 08:52:51 +00:00
Benedict Reuschling
fdb2feee16 Add a sentence to the man page explaining that the -d option
can only be used when ntpd is compiled with DEBUG support.

PR:             docs/138206
Submitted by:   Oliver Pinter (oliver dot pntr at gmail dot com)
MFC after:      5 days
Approved by:    roberto
2010-05-18 18:14:12 +00:00
Ivan Voras
27ad5065fe Slightly improve wording. 2010-05-17 11:18:33 +00:00
Poul-Henning Kamp
c6bfb71a6f Do not attempt to render a logrecord with length byte, until we have
decompressed all the bytes required.
2010-05-15 08:57:16 +00:00
Doug Barton
de2bfae478 Hide the creation and population of the temproot 2010-05-14 19:12:06 +00:00
Ulrich Spörlein
103e4932ee Sync apmd(8) with DragonflyBSD, bringing WARNS to 3
Reviewed by:	ed (partial, long time ago)
2010-05-14 14:26:56 +00:00
Christian Brueffer
d1ecad4b31 Wording fixes.
PR:		143454
Submitted by:	Warren Block <wblock@wonkity.com>
MFC after:	3 days
2010-05-14 01:45:05 +00:00
Christian Brueffer
0d83258df3 List /var/cron/tabs in FILES and add descriptions for the other entries.
PR:		145912
Submitted by:	Julian H. Stacey <jhs@berklix.com>
Obtained from:	OpenBSD
MFC after:	1 week
2010-05-14 01:25:30 +00:00
Ulrich Spörlein
0b31f1f731 mdoc: move remaining sections into consistent order
This pertains mostly to FILES, HISTORY, EXIT STATUS and AUTHORS sections.

Found by:	mdocml lint run
Reviewed by:	ru
2010-05-13 12:08:11 +00:00
Ulrich Spörlein
0afc94c17a mdoc: move CAVEATS, BUGS and SECURITY CONSIDERATIONS sections to the
bottom of the manpages and order them consistently.

GNU groff doesn't care about the ordering, and doesn't even mention
CAVEATS and SECURITY CONSIDERATIONS as common sections and where to put
them.

Found by:	mdocml lint run
Reviewed by:	ru
2010-05-13 12:07:55 +00:00
Zachary Loafman
07c1991012 extattr: Fix a signed/unsigned issue
Submitted by:       Matthew Fleming <matthew.fleming@isilon.com>
Reviewed by:        zml, dfr
2010-05-12 21:25:05 +00:00
Christian Brueffer
7b6299f1f5 The -d flag is non-optional.
PR:		143694
Submitted by:	Nikolai Saoukh <nms+bsd@otdel-1.org>
MFC after:	1 week
2010-05-12 01:33:51 +00:00
Kai Wang
ef6de0e1d8 Catch up with libusbhid merge (rev 205728).
hid_get_data() now expects that the hid data passed in always contains
the report ID byte. Thus we should not skip the the report ID byte in
hid_interrupt().  Also, if HUP_KEYBOARD usage is an array, do not try
to modify the 'data' pointer, instead, increase the hid_item_t field
'pos' by 'report_size' before calling hid_get_data() during each
iteration.

PR:			usb/146367
Reported and tested by:	Alex Deiter
Pointy hat to:	    	kaiw
Reviewed by:	    	emax
2010-05-09 09:20:25 +00:00
Fabien Thomas
782434abe5 Rework the calltree top view by critical callchain.
The percentage show is the sum of the cost for the codepath.

MFC after: 1 week
2010-05-07 19:48:50 +00:00
Kirk McKusick
e27ed89aef Merger of the quota64 project into head.
This joint work of Dag-Erling Smørgrav and myself updates the
FFS quota system to support both traditional 32-bit and new 64-bit
quotas (for those of you who want to put 2+Tb quotas on your users).

By default quotas are not compiled into the kernel. To include them
in your kernel configuration you need to specify:

options         QUOTA                   # Enable FFS quotas

If you are already running with the current 32-bit quotas, they
should continue to work just as they have in the past. If you
wish to convert to using 64-bit quotas, use `quotacheck -c 64';
if you wish to revert from 64-bit quotas back to 32-bit quotas,
use `quotacheck -c 32'.

There is a new library of functions to simplify the use of the
quota system, do `man quotafile' for details. If your application
is currently using the quotactl(2), it is highly recommended that
you convert your application to use the quotafile interface.
Note that existing binaries will continue to work.

Special thanks to John Kozubik of rsync.net for getting me
interested in pursuing 64-bit quota support and for funding
part of my development time on this project.
2010-05-07 00:41:12 +00:00
Fabien Thomas
176755d33e Exclude undefined symbol from ELF file when doing function resolve.
MFC after: 3 days
2010-05-06 20:54:19 +00:00
Kirk McKusick
945f418ab8 Final update to current version of head in preparation for reintegration. 2010-05-06 17:37:23 +00:00
Rick Macklem
56cfc5ed12 If the "-alldirs" export option was used for the V4: line, mountd
would crash in check_options() since dp == NULL for the V4: line.
This patch moves the check for options allowed on the V4: line to
ahead of where dp is used to avoid this crash.

Reported by:	mamalos AT eng.auth.gr
MFC after:	1 week
2010-05-06 00:24:08 +00:00
Daniel Gerzo
35939b04d3 - fix typo 2010-05-05 08:43:47 +00:00
Navdeep Parhar
d6da836201 Add support for hardware filters to cxgb(4). The T3 chip can inspect
L2/3/4 headers and can drop or steer packets as instructed.  Filtering
based on src ip, dst ip, src port, dst port, 802.1q, udp/tcp, and mac
addr is possible.  Add support in cxgbtool to program these filters.
Some simple examples:

Drop all tcp/80 traffic coming from the subnet specified.
# cxgbtool cxgb2 filter 0 sip 192.168.1.0/24 dport 80 type tcp action drop

Steer all incoming UDP traffic to qset 0.
# cxgbtool cxgb2 filter 1 type udp queue 0 action pass

Steer all tcp traffic from 192.168.1.1 to qset 1.
# cxgbtool cxgb2 filter 2 sip 192.168.1.1 type tcp queue 1 action pass

Drop fragments.
# cxgbtool cxgb2 filter 3 type frag action drop

List all filters.
# cxgbtool cxgb2 filter list
index         SIP                DIP     sport dport VLAN PRI P/MAC type Q
    0     192.168.1.0/24         0.0.0.0     *    80    0 0/1 */*    tcp -
    1         0.0.0.0/0          0.0.0.0     *     *    0 0/1 */*    udp 0
    2     192.168.1.1/32         0.0.0.0     *     *    0 0/1 */*    tcp 1
    3         0.0.0.0/0          0.0.0.0     *     *    0 0/1 */*   frag -
16367         0.0.0.0/0          0.0.0.0     *     *    0 0/1 */*      * *

MFC after:	2 weeks
2010-05-05 00:41:40 +00:00
Norikatsu Shigemura
2db9a1171c Add support run services_mkdb(8).
Approved by:	dougb, imp (mentor)
Reviewed by:	ume
MFC after:	2 weeks
2010-05-04 11:25:04 +00:00
Warner Losh
02b9c3f52f sparc64, and possibly other architectures, pads the length of the
section holding the config file to sh_addralign bytes using NULs.
This bogusly triggers an assert.  Break out of the loop when we hit an
NUL within that many bytes of the end.

MFC after:	3 days
2010-05-01 07:25:28 +00:00
Jung-uk Kim
3f5e024c14 Merge ACPICA 20100428. 2010-04-28 22:25:27 +00:00
Kirk McKusick
a4bf5fb987 Update to current version of head. 2010-04-28 05:33:59 +00:00
Warner Losh
4bc2b0b76d Require the option that's mapped be listed in the options file. This
will allow people with old config options to either have it just work
(if config is new enough), or get a version error (if their config is
about 7.0 or newer) rather than getting a cryptic error about
duplicated options in the options file, or getting an error about an
unknown option, at which point they'd update their config file only to
learn they need a new config, only to learn they didn't really need to
update their config file...  All this because our version checking was
in the wrong place for the past decade...

# hopefully this is the last change, and we'll be able to config with an
# 8.0 GENERIC file on stable/8 after I merge this change and add the
# compat options.

MFC after:	3 days
2010-04-27 06:14:30 +00:00
Warner Losh
012ead2f2c Redo how we add compat options so as to be compatible with old
versions of config.  Remove support for the syntax OLD = NEW form the
options file, and instead have a new file $S/conf/options-compat.
This file will be parsed as OLD NEW on each line.  Bump version of
config.  Since nothing in -current ever used this, there's no hazards
for current users, so I'm not bumping the version in the
Makefiles.$MACHINE.  No need, really, for this version bump in
-current, but this was introduced into -stable before I realized the
version check was ineffective there, so the verison bump doesn't hurt
here and keeps the two branches in sync, versionwise, after the MFC.

MFC after:	3 days
2010-04-27 05:38:26 +00:00
Warner Losh
90aa4f9e8c Move checking the version up from Makefile generation to just after
we've parsed the config file.  Makefile generation is too late if
we've introduce changes to the syntax of the metafiles to warn about
version skew, since we have to try to parse them and we get an parse
error that's rather baffling to the user rather than a 'your config is
too old, upgrade' which we should get.

We have to defer doing it until after we've read the user's config
file because we define machinename there.  The version required to
compile the kernel is encoded in Makefile.machinename.  There's no
real reason for this to be the case, but changing it now would
introduce some logistical issues that I'd rather avoid for the moment.
I intend to revisit this if we're still using config in FreeBSD 10.

This also means that we cannot introduce any config metafile changes
that result in a syntax error or other error for the user until 9.0 is
released.  Otherwise, we break the upgrade path, or at least reduce
the usefulness of the error messages we generate.

# This implies that the config file option mapping will need to be redone.

MFC after:	3 days
2010-04-27 05:04:32 +00:00
Jeff Roberson
113db2dddb - Merge soft-updates journaling from projects/suj/head into head. This
brings in support for an optional intent log which eliminates the need
   for background fsck on unclean shutdown.

Sponsored by:   iXsystems, Yahoo!, and Juniper.
With help from: McKusick and Peter Holm
2010-04-24 07:05:35 +00:00
Florent Thoumie
762c7db2e8 - Take libinstall.a out of pkg_install and make it a proper shared library.
- Rework the wrapper support to check libpkg version as well as pkg_install
version.
- Add libfetch to _prebuild_libs.
- There are no new features introduced.

Notes: the API is not stable, so basically, do not use libpkg in your
projects for now. Also there's no manpage for libpkg yet, because the API
will change drastically. I repeat, do not use libpkg for now.
2010-04-23 11:07:43 +00:00
Alexander Leidinger
7ab4cc53fd Revert r206179 (by imp) and do something similar which is more consistent
with all other corresponding CTF places by changing the corresponding
code which is generated by config(8). Or in short, move the '@' from
the variable definition to the use of the variable. [1]

While I'm here break up a long line. [2]

Discussed with:	imp [1,2], bde [2]
2010-04-22 09:20:17 +00:00
Rebecca Cran
4e64643386 Remove the reference to DD mode, and replace with Expert mode. Also, make
sure the "Q = Finish" text is visible.
Reword the boot manager screen to try and avoid confusion, and make the
order of the menu items match that in sysinstall.

PR:		bin/142916
Submitted by:	Jeremy Chadwick <freebsd at jdc.parodius.com>
Reviewed by:	randi
Approved by:	rrs (mentor)
MFC after:	1 week
2010-04-21 19:03:34 +00:00
Rebecca Cran
aff6448371 Make the "Q = Finish" text visible when running sysinstall as a normal
application.  Reword the boot manager screen to try and avoid confusion.

Reviewed by:	randi
Approved by:	rrs (mentor)
MFC after:	1 week
2010-04-21 18:55:44 +00:00
Randi Harper
97293c5833 Fix bug introduced in r198317: Don't leak a file descriptor after scanning for network devices.
Approved by:	cperciva (mentor)
MFC after:	1 week (original commit + bugfix)
2010-04-21 12:02:45 +00:00
Fabien Thomas
cb5a415375 Apply threshold filter to root node in calltree view.
MFC after: 3days
2010-04-21 11:50:13 +00:00
Warner Losh
bd34cda61a Bump minor version of config to reflect the new option remapping
feature.  The kernel makefiles have specifically not been bumped
because nothing uses this new feature and doing so forces everybody to
recompile for no good reason.  This chnage will be MFC'd where the
kernel version numbers for amd64 and ia64 will be bumped, since those
are the only two that have use the option remapping feature.  Once
merged, this will give a better error message to folks that are using
buildkernel without buildworld or kernel-toolchain to update their
kernels.

MFC after:	3 days
2010-04-20 20:36:38 +00:00
Warner Losh
e1a4e3fa37 Allow option aliasing. Lines of the form:
OLD_OPT = NEW_OPT

in options* files will now map OLD_OPT to NEW_OPT with a friendly
message.  This is indented for situations where we need to preserve an
interface in the config file in an upwards compatible fashion on a
stable branch.

Reviewed by:	nwhitehorn@
MFC after:	3 days
2010-04-15 15:10:46 +00:00
Fabien Thomas
410c766274 Move fatal error at the right place.
Fix exit from top mode when checking if PMC is available.

MFC after: 3 days
2010-04-14 21:53:27 +00:00
Pyun YongHyeon
451f0bf403 Add sge(4) to the list of supported network interface. 2010-04-14 20:54:23 +00:00
Ulrich Spörlein
aa12cea2cc mdoc: order prologue macros consistently by Dd/Dt/Os
Although groff_mdoc(7) gives another impression, this is the ordering
most widely used and also required by mdocml/mandoc.

Reviewed by:	ru
Approved by:	philip, ed (mentors)
2010-04-14 19:08:06 +00:00
Ed Schouten
6d2b7c381b Don't forget to catch realloc() errors. 2010-04-11 12:07:03 +00:00
Ed Schouten
aacd7d6afc Alphabetically sort the output of lastlogin(8).
According to the manpage, the entries have to be sorted by uid. This is
no longer possible, since our utmpx implementation is completely unaware
of user IDs. You can safely add entries for multiple users sharing the
same uid.

Make the output less random by sorting everything by name.
2010-04-11 12:02:13 +00:00
Bernhard Schmidt
632ee7e3a4 Add WPA-None support:
* WPA-None requires ap_scan=2:
  The major difference between ap_scan=1 (default) and 2 is, that no
  IEEE80211_IOC_SCAN* ioctls/functions are called, though, there is a
  dependency on those. For example the call to wpa_driver_bsd_scan()
  sets the interface UP, this never happens, therefore the interface
  must be marked up in wpa_driver_bsd_associate(). IEEE80211_IOC_SSID
  also is not called, which means that the SSID has not been set prior
  to the IEEE80211_MLME_ASSOC call.
* WPA-None has no support for sequence number updates, it doesn't make
  sense to check for replay violations..
* I had some crashes right after the switch to RUN state, issue is
  that sc->sc_lastrs was not yet defined.

Approved by:	rpaulo (mentor)
MFC after:	3 weeks
2010-04-10 13:54:00 +00:00
Jung-uk Kim
cdfd79031a Add an entry for the old Beastie logo saver and re-sort. 2010-04-07 17:40:48 +00:00
Hajimu UMEMOTO
449c161202 Fix compilation error on amd64.
Reported by:	stefanf
MFC after:	2 weeks
2010-04-04 15:21:09 +00:00
Hajimu UMEMOTO
8812e23c43 Fix compilation error on 9-CURRENT.
Reported by:	nyan
MFC after:	2 weeks
2010-04-04 14:23:28 +00:00
Hajimu UMEMOTO
0b25da7e0b services_mkdb; generate db file from services(5) to increase
speed of getserv*()

Obtained from:	NetBSD
MFC after:	2 weeks
2010-04-04 08:38:14 +00:00
Florent Thoumie
b2d7e80ed1 Bump PKG_INSTALL_VERSION to 20100403. 2010-04-03 10:57:13 +00:00
Florent Thoumie
fc6d543f21 Fix pkg_delete, check if the file we're trying to delete is a
symlink before complaining that it doesn't exist. Typical case
would be a leftover library symlink that's left over after the
actual library has been removed.

Reported by:	tabthorpe
2010-04-03 10:55:11 +00:00
Yaroslav Tykhiy
0ca97bb61f Keep the list of default keywords sorted so that paranoid folks like me
don't try to find a hidden meaning in the strange order.  The list used
to be sorted in rev. 1.1 from 4.4BSD but the order was broken as soon as
in rev. 1.2 by a single-character fix.

MFC after:	3 days
2010-04-03 00:47:48 +00:00
Ed Schouten
9c8d0b9600 Properly initialize the timestamp when using ac -w.
When using ac -w, we must use the last timestamp to terminate the log
file. I accidentally removed this when I ported the code to use utmpx.

Reported by:	avg
2010-04-02 14:30:56 +00:00
Fabien Thomas
c86819ec59 Improve "top" header by:
- Display sample received per PMCs (or merged PMCs).
- Display percentage vs all samples
2010-04-02 13:34:28 +00:00
Warner Losh
136ca0d1d5 We don't need to note that mkproto is missing anymore. It is
definitely OBE in a number of ways, and likely should have been
removed in 2000, not 2010.
2010-04-01 17:04:37 +00:00
Florent Thoumie
094f117522 Various fixes.
- Replace hardcoded INDEX version. [1]
- Fix a buffer overlap. [2]
- Remove empty package when fetching fails and -K is used. [3]
- Remove useless chmod2() after mkdtemp(3). [4]
- Replace mkdir(1) call with mkdir(2). [5]
- Get rid of some vsystem() calls.
- Switch from lstat(2) to open(2) in fexists().
- Try rename(2) in move_file() first.
- Bump PKG_INSTALL_VERSION to 20100401.

PR:		bin/145101 [1], bin/139492 [2], bin/144919 [3]
		bin/144920 [4], bin/144921 [5]
Submitted by:	gcooper [1,2,3,4,5]
2010-04-01 14:27:29 +00:00
Xin LI
ded7840825 Sync with OpenBSD:
- avoid coredump when there's only one token on a line;
 - Use calloc();
 - Remove a line inherited from example mdoc.

Obtained from:	OpenBSD
MFC after:	1 month
2010-03-30 21:54:25 +00:00
Ruslan Ermilov
53d55e9756 - Handle calloc() allocation failures.
- Fixed a comment.
- 2 -> EXIT_FAILURE in some places.
- errx() -> err() where appropriate.

PR:		144644
Submitted by:	Garrett Cooper
2010-03-30 13:46:40 +00:00
Maxim Konovalov
3e6b66eecc o Remove a duplicate reference to -f flag in the SYNOPSYS section.
o Improve wording.

PR:		docs/144407
Submitted by:	gcooper
MFC after:	1 week
2010-03-30 09:22:33 +00:00
Jung-uk Kim
f46f4ae113 Print memory model of the video mode except for planar memory model.
'P', 'D', 'C', 'H', 'V' mean packed pixel, direct color, CGA, Hercules,
VGA X memory models respectively where they have fixed number of planes.
2010-03-29 20:12:44 +00:00
Fabien Thomas
9ba84a88b8 Wait for pmc name in the log before displaying data.
This will solve an abort in case of low throughput PMCs.

MFC after: 3days
2010-03-28 22:46:56 +00:00
Ed Schouten
99742a231f Change all our own code to use st_*tim instead of st_*timespec.
Also remove some local patches to diff(1) which are now unneeded.
2010-03-28 13:16:08 +00:00
Fabien Thomas
75109b48f4 Do not overflow the term in the case of multi-line display.
MFC after: 3days
2010-03-26 14:29:57 +00:00
Maxim Konovalov
a787a4cbb1 o Trim leading w/space.
PR:		docs/145030
Submitted by:	olgeni
MFC after:	1 week
2010-03-26 05:34:13 +00:00
Shteryana Shopova
438be77d54 Now actually implement reading/refreshing/returning data from the pfTablesAddrTable
and modify the BEGEMOT-PF-MIB to add support for IPV6 address' statistics in the PF
tables via pfTablesAddrNetType and pfTablesAddrNet. While here, upgrade the
pf_tree.def file to the new format that includes enumerated values. Also make sure
to return SNMP_ERR_NOSUCHNAME for ALTQ objects, if ALTQ is disabled, so that the agent
will know to skip the pfAltq subtree when servicing GETNEXT requests from SNMP clients
(otherwise snmpwalk on begemotPf would stop at the pfAltq subtree with bsnmpd returning
SNMP_ERR_GENERR).
2010-03-24 16:07:33 +00:00
Gavin Atkinson
0d0a5555c2 wollman@ has OK'd dropping his maintainership of zic(8)
Submitted by:	linimon
Approved by:	wollman (via linimon)
2010-03-20 11:05:11 +00:00
Ed Schouten
d7f1607c6a Chop off excessive long hostnames to keep the table structure intact.
This makes lastlogin(8) use exactly the same printf format as last(1).
2010-03-20 09:29:25 +00:00
Shteryana Shopova
9315567023 Make sure the snmp_pf module will first refresh its entires if necessary,
then find a specific entry, and get the requested value. So far, it found
the specific entry, refreshed the entry list if necessary, and got the
requested value from the found entry. The problem is that refreshing nukes
all old entries and replaces them with new ones and the obtained entry
pointer was no longer valid after the refresh.

Reviewed by:		bz, philip
MFC after:		1 week
2010-03-19 09:53:25 +00:00
Ed Schouten
f97f9525ba Properly progress through the list of IPv6 addresses using in6_addr size.
Right now if a jail has multiple IPv6 addresses, it will print them
shifting only 4 bytes at a time. Example:

	2001:4dd0:ff41::b23f:a9
	2001:4dd0:ff41::b23f:aa

Becomes:

	2001:4dd0:ff41::b23f:a9
	ff41::b23f:a9:2001:4dd0

By casting to in6_addr, it uses the correct offsets.

MFC after:	1 week
2010-03-18 20:13:04 +00:00
Shteryana Shopova
72d420c708 Add support for retrieving labeled pf filter rule counters.
PR:		bin/132847
Submitted by:	Szalai Andras <szalai (dot) bandi (at) gmail.com>
2010-03-18 14:54:31 +00:00
Qing Li
78f3ac9cdb Need to set the proper flag bit when inserting ARP
entries into the kernel.

MFC after:	3 days
2010-03-18 00:23:39 +00:00
Kirk McKusick
516ad57b74 Debugging nits found while testing the new 64-bit quota code. 2010-03-16 06:12:30 +00:00
Joerg Wunsch
0a47b5f57f then -> than
MFC after:	1 day
2010-03-15 16:06:52 +00:00
Doug Barton
c9bb666937 Make it more clear in the docs that -a is not compatible with -iFU,
and enforce this in the code. Apparently a lot of users mistakenly
combine -a with these flags and are then mystified that no changes
were made.

While I'm here, fix a trailing space in mergemaster.8
2010-03-14 05:22:46 +00:00
Ulrich Spörlein
63d46d1d5e Fix several typos in macros or macro misusage.
Found by:	make manlint
Reviewed by:	ru
Approved by:	philip (mentor)
2010-03-12 10:01:06 +00:00
Fabien Thomas
b44906e506 Change the way shutdown is handled for log file.
pmc_flush_logfile is now non-blocking and just ask the kernel
to shutdown the file. From that point, no more data is
accepted by the log thread and when the last buffer is flushed
the file is closed.

This will remove a deadlock between pmcstat asking for
flush while it cannot flush the pipe itself.

MFC after: 3 days
2010-03-08 19:58:00 +00:00
Fabien Thomas
2aa983e5ad Bug fixed:
- no display on serial terminal in top mode.
- display alignment for continuation string.
- correct invalid value used for display limit.

MFC after:	3 days
2010-03-05 23:08:19 +00:00
Jung-uk Kim
ca3cf4fa2c Merge ACPICA 20100304. 2010-03-05 21:39:16 +00:00
Warner Losh
515b186861 moused is useful even without usb, so remove comment asking if it is. 2010-03-04 20:31:49 +00:00
Ulrich Spörlein
7f72022f3d mount_nwfs(8): make WARNS=6 clean
uid_t and gid_t are unsigned. While initializing them to -1 and later
checking against -1 to see if they are still at their default usually
works, introduce two new flags and stop the inband signalling.

Approved by:	ed (co-mentor)
2010-03-04 16:07:14 +00:00
Dag-Erling Smørgrav
1a0fda2b54 IFH@204581 2010-03-04 13:35:57 +00:00
Dag-Erling Smørgrav
7c54172a4f Fix warnings + indentation + utmpx 2010-03-04 10:57:52 +00:00
Xin LI
90bb63899b Make 'make manlint' happy. No actual visible change. 2010-03-03 23:11:14 +00:00
Ulrich Spörlein
7729e3ba40 Remove redundant WARNS?=6 overrides and inherit the WARNS setting from
the toplevel directory.

This does not change any WARNS level and survives a make universe.

Approved by:        ed (co-mentor)
2010-03-02 18:44:08 +00:00
Ulrich Spörlein
47e1a877c5 Always assign WARNS using ?=
- fix some nearby style bugs
- include Makefile.inc where it makes sense and reduces duplication

Approved by:	ed (co-mentor)
2010-03-02 16:58:04 +00:00
Ulrich Spörlein
bd2c49af72 rtsol(8)/rtsold(8): make WARNS=3 clean
It is actually WARNS=6 clean for non-strict alignment archs.

Approved by:	ed (co-mentor)
2010-02-27 10:19:39 +00:00
Ruslan Ermilov
c59ee18a21 Fixed static linkage. 2010-02-26 09:41:16 +00:00
Edwin Groothuis
dcfeda6122 Split the contributed code from libc/stdtime from lib/libc/stdtime
to contrib/tzcode/stdtime.
2010-02-26 06:44:00 +00:00
Edwin Groothuis
97dcdbd450 From contrib/tzcode:
The Makefiles are leftovers from the copies and should live in usr.sbin/zic/*

From usr.sbin/zic:
The sources are from a vendor contributed source, therefore should
live in contrib/tzcode/zic.
2010-02-25 21:10:27 +00:00
Ruslan Ermilov
bee10047c0 Fixed dependencies (make checkdpadd). 2010-02-25 20:24:19 +00:00
Weongyo Jeong
4f0c2fae8d Add bwn(4) driver. 2010-02-25 19:47:47 +00:00
Navdeep Parhar
5310975100 Allow cxgbtool to build with WARNS=6
MFC after:	1 week
2010-02-23 23:01:41 +00:00
Gavin Atkinson
1901b12462 Add a "-x" option to chown(8)/chgrp(1) similar to the same option in
du(1), cp(1) etc, to prevent the crossing of mountpoints whilst using the
commands recursively.

PR:		bin/130855
Submitted by:	keramida
MFC after:	1 month
2010-02-21 10:14:06 +00:00
Ulrich Spörlein
8fa03d08ca Fix common misspelling of hierarchy
Pointed out by:		bf1783 at gmail
Approved by:		np (cxgb), kientzle (tar, etc.), philip (mentor)
2010-02-20 10:19:19 +00:00
John Baldwin
fe2f808774 Fix mptutil's method for locating disk devices attached to a specific
mpt(4) controller.  Previously, the code assumed that multiple match
patterns provided to an XPT_DEV_MATCH request were ANDed together.
Instead, they are ORed.  Instead, to match peripherals for a specific bus,
one query needs to be performed to lookup the path ID of the bus.  A second
query can then be performed matching peripherals attached to that path.
This approach also makes the code a bit cleaner as the returned match
results do not mix bus and perphierals.

Reported by:	several folks
MFC after:	1 week
2010-02-19 15:16:00 +00:00
John Baldwin
5f1f6da8ba - Don't emit a warning in 'show adapter' if the IOC2 or IOC6 pages are not
present.  mpt(4) controllers that do not support RAID do not have an IOC6
  page, for example.
- Correct a check for a missing page error in a debug function.

MFC after:	1 week
2010-02-19 14:31:01 +00:00
John Baldwin
73401fbaa0 Fix a typo.
Submitted by:	Jakub Lach  jakub_lach of mailplus pl
2010-02-19 14:27:32 +00:00
Warner Losh
f77a51d7a8 Revert bogus change that snuck into r203972. 2010-02-17 06:11:05 +00:00
Warner Losh
08ab090881 The NetBSD Foundation has given permission to remove clause 3 and 4
from their liceense.

Obtained from:	NetBSD
2010-02-16 21:47:05 +00:00
Ulrich Spörlein
54673381cd Add missing newline in last line of file.
Uncovered via:	fromcvs vs. svn
Approved by:	ed (co-mentor)
2010-02-16 09:10:21 +00:00
Ruslan Ermilov
929683056e Show when an ARP entry expires.
MFC after:	1 week
2010-02-15 14:29:17 +00:00
Fabien Thomas
0b86b1bb01 - Reorganize code in 'plugin' to share log processing.
- Kcachegrind (calltree) support with assembly/source
code mapping and call count estimator (-F).
- Top mode for calltree and callgraph plugin (-T).

MFC after:	1 month
2010-02-11 22:51:44 +00:00
Warner Losh
923dd9a7a7 When you have multiple addresses on the same network on different
interfaces (such as when you are part of a carp pool), and you run
rpcbind -h to restrict which interfaces have rpc services, rpcbind can
none-the-less return addresses that aren't in the -h list.  This patch
enforces the rule that when you specify -h on the command line, then
services returned from rpcbind must be to one of the addresses listed
in -h, or be a loopback address (since localhost is implicit when
running -h).

The root cause of this is the assumption in addrmerge that there can
be only one interface that matches a given network IP address.  This
turns out not to be the case.  To retain historical behavior, I didn't
try to fix the routine to prefer the address that the request came
into, since I didn't know the side effects that might cause in the
normal case.  My quick analysis suggests that it wouldn't be a
problem, but since this code is tricky I opted for the more
conservative patch of only restricting the reply when -h is in effect.

Hence, this change will have no effect when you are running rpcbind
without -h.

Reviewed by:	alfred@
Sponsored by:	iX Systems
MFC after:	2 weeks
2010-02-09 18:10:56 +00:00
Warner Losh
b207c9d856 Anything that casts struct sockaddr * to struct sockaddr_foo is safe
due to careful design.  We've not yet figured out how to properly
annotate the sockaddr structs to communicate this to the compiler and
there's a number of constructs in the tree that make this annotation
challenging.

As such, reduce warns to 3 here because this code really isn't warns 6
safe, even if it kinda sorta appears to be on intel (which has no such
alignment restrictions).  Warns 4 adds the -Wcast-align warning.

# fixes the mips tinderbox build
2010-02-09 17:16:13 +00:00
Rebecca Cran
b5c2248595 Xorg isn't treated as a distribution, so /usr/X11R6/lib shouldn't be configured when running ldconfig.
PR:		bin/138945
Approved by:	rrs (mentor)
MFC after:	3 days
2010-02-08 21:29:34 +00:00
Martin Blapp
66df920cc9 If there is only one NIC in the system that is up and running, the
interface specifier on the command line can be ommited.

Besides of this, the bpf is being reused for each machine
that has to be woken up.

Submitted by:	Marc Balmer <marc@msys.ch>
2010-02-08 20:57:49 +00:00
Warner Losh
200ad46cd3 Initialize fromlen before calling recvfrom to avoid passing in random
stack garbage.

Obtained from:	NetBSD 1.13
2010-02-07 07:50:41 +00:00
Warner Losh
7a377edc31 Since APM is a legacy technology, that won't be adapted to other
platforms, move the test for i386 from the Makefile to powerd.c.  The
powerpc specific checks are already done this way...
2010-02-04 07:26:26 +00:00
Hajimu UMEMOTO
62fd5fd625 Exclude the interfaces which IPv6 and/or accepting RA is disabled
from the auto probed interface list.

MFC after:	1 week
2010-02-02 18:38:17 +00:00
Hajimu UMEMOTO
3ce74ea2c5 Make -a option actually work.
MFC after:	1 week
2010-02-02 16:02:09 +00:00
Juli Mallett
c1ae57c6bb Correct copy-paste typo from previous option description. 2010-01-27 07:37:39 +00:00
John Baldwin
2e9f91310b Don't pop up the menu to select a documentation language for non-interactive
installs.  Default to not installing any documentation in that case.

MFC after:	1 week
2010-01-26 15:29:53 +00:00
Pyun YongHyeon
69618fcf1f Connect smbfs related libraries and tool on sparc64.
Reviewed by:	marius
2010-01-25 18:52:47 +00:00
Ed Schouten
3c247358fe Remove unneeded setpassent() calls.
lastlogin no longer requires the use of the passwd database.
2010-01-24 14:29:40 +00:00
Stephen McKay
97d21c886d Shrink encoded line length from 76 to 72 characters.
Some Exchange systems wrap lines over 75 characters long while converting
messages to quoted-printable, preventing ctm_rmail from reassembling
emailed deltas.  For a negligible loss of encoding efficiency, this change
allows ctm deltas to once more pass through Exchange undamaged.
2010-01-24 11:54:32 +00:00
Florent Thoumie
7735b3839a - Add support for UPDATING remote fetching.
- Reorganize EXAMPLES section in pkg_updating(1).
- Style fixes.
- Bump PKG_INSTALL_VERSION to 20100122.

Submitted by:	beat
MFC after:	1 week
2010-01-22 23:32:10 +00:00
Doug Barton
a68c7fa928 Make -U once again honor -D after my change to consolidate setting
of MTREEDB with DESTDIR.

PR:		bin/143089
Submitted by:	Anton Yuzhaninov <citrin@citrin.ru>
2010-01-22 17:17:47 +00:00
Jung-uk Kim
9a179dd8be Merge ACPICA 20100121. 2010-01-21 21:14:28 +00:00
Ed Schouten
0806dd9238 Remove stale references to utmp(5) and its corresponding filenames.
I removed utmp and its manpage, but not other manpages referring to it.
2010-01-21 17:25:12 +00:00
Nathan Whitehorn
deccdf0e17 Fix a bug when printing attributes from multiple files: buflen could be
longer than the length of the current attribute if the buffer were reused
and previously longer, so bits of the previous, longer attribute would be
written. Fix this by using the actual attribute length.
2010-01-21 03:49:18 +00:00
Xin LI
db75450166 Give the right value when complaining it being wrong.
Reported by:	danfe
MFC after:	3 days
2010-01-20 18:22:56 +00:00
Hiroki Sato
cbf58894c1 Simply ignore unsupported protocols listed in /etc/netconfig and
abort only if no transport is available.  This fixes
(INET && !INET6) and (!INET && INET6) case, for example.
2010-01-20 16:50:13 +00:00
Hiroki Sato
d04ef9128c Try a privileged port for binding whenever possible because the
ypbind daemon requires the ypserv daemon is running on a
privileged port.

Reported by:	Andrzej Tobola
2010-01-20 09:29:07 +00:00
Xin LI
ccc28f774a Add a new option, -P, which reverts newsyslog(8) to the old behavior,
which stops to proceed further, as it is possible that processes which
fails to create PID file get screwed by rotation.

Requested by:	stas
MFC after:	2 weeks
X-MFC with:	r200806
2010-01-20 01:07:38 +00:00
Bjoern A. Zeeb
592bcae802 Add ip4.saddrsel/ip4.nosaddrsel (and equivalent for ip6) to control
whether to use source address selection (default) or the primary
jail address for unbound outgoing connections.

This is intended to be used by people upgrading from single-IP
jails to multi-IP jails but not having to change firewall rules,
application ACLs, ... but to force their connections (unless
otherwise changed) to the primry jail IP they had been used for
years, as well as for people prefering to implement similar policies.

Note that for IPv6, if configured incorrectly, this might lead to
scope violations, which single-IPv6 jails could as well, as by the
design of jails. [1]

Reviewed by:	jamie, hrs (ipv6 part)
Pointed out by:	hrs [1]
MFC After:	2 weeks
Asked for by:	Jase Thew (bazerka beardz.net)
2010-01-17 12:57:11 +00:00
Antoine Brodin
622008b65d Unbreak world WITHOUT_NETGRAPH.
PR:		137487
Submitted by:	bf (previous version)
No objections:	net@
MFC after:	2 weeks
2010-01-16 12:20:26 +00:00
Ruslan Ermilov
aa4a335bae Use the newly brought %U macro. 2010-01-15 16:01:22 +00:00
Doug Barton
bc1b4f78f9 Oops, deleted one line too many. Add back the null case for IGNORE_MOTD 2010-01-15 04:09:22 +00:00
Doug Barton
705b2d5389 Now that we've officially arrived at FreeBSD 9, remove the IGNORE_MOTD
compat shim as advertised. This change should not be MFC'ed.
2010-01-15 03:56:48 +00:00
Joel Dahl
05c9bdf579 Fix a few whitespace issues and comment typos that I found while reading
through this file.
2010-01-14 22:04:08 +00:00
Ed Schouten
b5810e9449 Port all applications in usr.sbin/ from libulog to utmpx. 2010-01-13 18:17:53 +00:00
Ed Schouten
b5207b31c4 Port lastlogin(8) to utmpx.
While there, fix a bug I introduced previously. We must reopen the
database for each username passed on the command line. We must rewind
the database and search from the beginning.
2010-01-13 18:17:12 +00:00
Ed Schouten
e4ce5cb26c Port timed away from logwtmp(3). Let it use utmpx. 2010-01-13 18:15:46 +00:00
Ed Schouten
cf4d4e152c Port ac(8) to utmpx.
Similar to last(1), it must compare ut_id's instead of TTYs to determine
whether a session has been terminated. It must also use ut_type to
determine the type of the login record instead figuring it out by
itself.
2010-01-13 18:14:59 +00:00
Ed Schouten
adc17f0a42 Port ppp(8) to utmpx.
A nice thing about utmpx is that it makes it very easy to log sessions
that don't use TTYs. This is because the file is not indexed by TTY
slots anymore.

Silence from:	brian
2010-01-13 17:54:32 +00:00
Andrew Thompson
941e286383 Add a driver by Fredrik Lindberg for Option HSDPA USB devices. These differ
from standard 3G wireless units by supplying a raw IP/IPv6 endpoint rather than
using PPP over serial. uhsoctl(1) is used to initiate and close the WAN
connection.

Obtained from:	Fredrik Lindberg <fli@shapeshifter.se>
2010-01-13 03:16:31 +00:00
Andrew Thompson
86a06bed75 Print error messages to stderr.
Submitted by:	Hans Petter Selasky
2010-01-10 19:21:23 +00:00
Antoine Brodin
a16bfb395c Add missing library dependency.
MFC after:	1 month
2010-01-09 18:59:03 +00:00
Bjoern A. Zeeb
f1727e425a Correct spelling.
Submitted by:	(pluknet gmail.com)
MFC after:	4 days
X-MFC with:	r201806
2010-01-09 15:37:24 +00:00
Christian Brueffer
5f9f9bd940 Various language fixes. Also fixed the URL to totd, obtained from NetBSD.
PR:		38061
Submitted by:	Chris Pepper <pepper@rockefeller.edu>
MFC after:	1 week
2010-01-09 10:24:09 +00:00
Bjoern A. Zeeb
558312167d Switch traceroute over to make use of proper in-kernel source
address selection.

Reviewed by:	rwatson, fenner
MFC after:	1 week
X-MFCable to:	stable/8, stable/7 (after r183571).
PR:		kern/139454
Tested by:	Frank Steinborn (steinex nognu.de)
2010-01-08 16:59:28 +00:00
Doug Barton
f94a6780d9 Update copyright date
Update delete_temproot() to include the error message if it fails,
and clean up the places where it's called.

If there are no files left in temproot when the comparison is done
delete it without prompting. This should make "automated" runs of
mergemaster without -a a little easier.

Document the new behavior in the man page.
2010-01-08 00:05:10 +00:00
David Malone
88e84e0fdd This now passes a make universe with WARNS=6. 2010-01-07 09:40:34 +00:00
Andrew Thompson
cf109686d0 Sync to p4
- Add new quirks commands and the '-d' option optionally to specify the ugen device.

Submitted by:	Hans Petter Selasky
2010-01-07 00:50:45 +00:00
David Malone
18c2d3f245 New style function definitions.
Fix constness problem - don't know that pstatus won't change a string with no
whitespace.
2010-01-05 20:40:40 +00:00
Ed Schouten
24cb3af593 Unbreak bootparamd when setting WITHOUT_NIS.
Submitted by:	bf1783 googlemail com
2010-01-04 18:08:16 +00:00
Xin LI
f3f0a6c957 Test index value is within the range before using it to reference
array member.

PR:		bin/141838
Submitted by:	Henning Petersen <henning.petersen@t-online.de>
MFC after:	2 weeks
2010-01-04 18:04:36 +00:00
Konstantin Belousov
4176dd5267 Modernize scandir(3) and alphasort(3) interfaces according to the IEEE
Std 1003.1-2008. Both Linux and Solaris conforms to the new definitions,
so we better follow too (older glibc used old BSDish alphasort prototype
and corresponding type of the comparision function for scandir). While
there, change the definitions of the functions to ANSI C and fix several
style issues nearby.

Remove requirement for "sys/types.h" include for functions from manpage.

POSIX also requires that alphasort(3) sorts as if strcoll(3) was used,
but leave the strcmp(3) call in the function for now.

Adapt in-tree callers of scandir(3) to new declaration. The fact that
select_sections() from catman(1) could modify supplied struct dirent is
a bug.

PR:	standards/142255
MFC after:	2 weeks
2010-01-04 15:40:17 +00:00
Antoine Brodin
b8cf11192e Complete ntptrace(8) removal:
- do not install man page
- update ObsoleteFiles.inc

Approved by:	roberto@
2010-01-03 22:29:06 +00:00
Gavin Atkinson
a196444862 The default hash table size is 257 not 255. Reword the rest of the line
slightly while here.

PR:		bin/121671
Submitted by:	Artis Caune  artis.caune gmail.com
Approved by:	ed (mentor)
2010-01-03 19:28:51 +00:00
Ed Schouten
fffa535e95 Lower WARNS for sendmail.
Even though it builds with WARNS=2, some users link sendmail from the
base system against SASL. This doesn't build in this case.

Reported by:	Andrzej Tobola <ato iem pw edu pl>
2010-01-03 15:32:25 +00:00
Martin Blapp
bb40fa6f73 Make it clear that "interface" is one out of possibly many interface of the
local machine (s/the network interface/a network interface).

Submitted by:	Marc Balmer <marc@msys.ch>
MFC after:	3 days
2010-01-02 17:29:13 +00:00
Yoshihiro Takahashi
a8bb63996e Use UFS2 as default filesystem. Now pc98's boot2 works for UFS2.
MFC after:	2 week.
2010-01-02 12:42:33 +00:00
Ed Schouten
71ccf09269 The last big commit: let usr.sbin/ use WARNS=6 by default. 2010-01-02 11:07:44 +00:00
Ed Schouten
1fa2ff1f64 Remove unused variables. 2010-01-02 11:06:39 +00:00
Ed Schouten
3a61cc0822 Mark ftwv as __unused. This compare function does not need it. 2010-01-02 11:06:11 +00:00
Ed Schouten
9a958de54c ANSIfy some more tools in usr.sbin/.
Most of these tools build with WARNS=6, except for their use of K&R
function declarations.
2010-01-02 11:05:34 +00:00
Doug Barton
15768c780a If we are using -p it does not make any sense to even create the
MTREENEW file since it will never be used.
2009-12-31 04:07:13 +00:00
Doug Barton
3dbee1749a It's not necessary to include both Op and Fl for command line options
included in the text, so use only the latter.

Clarify that using -U doesn't make sense in combination with -a
2009-12-30 23:26:29 +00:00
Doug Barton
6fb3661e8f Document the DELETE_STALE_RC_FILES option introduced in r201291. This is
an "rc file only" option by design.

While I'm here, update the comments in the example rc file to indicate
which command line options they relate to, and correct the defaults
for a couple of options.
2009-12-30 23:16:14 +00:00
Doug Barton
8d54ee3c0b Add some patches contributed by jhb:
1. Don't prompt the user for "-U but no db" error if we're using -a
2. Add an option to delete stale rc.d files automatically if the user
has DELETE_STALE_RC_FILES in their rc file. Lack of command line option
for this is not an oversight.
3. Add []'s around the terminal $ for the $FreeBSD$ test for -F

For one bug raised by jhb I did a more thorough solution:
There were a lot of things that "snuck in" between the end of the test
for -r and the start of the comparison. One of them is the creation of
the mtree db, as pointed out by jhb. Fix this problem more thoroughly
by moving the end of the test down to where it should/used to be, right
before the comparison. As a result, indent the interloping code to match.
2009-12-30 23:14:03 +00:00
Qing Li
c7ab66020f The proxy arp entries could not be added into the system over the
IFF_POINTOPOINT link types. The reason was due to the routing
entry returned from the kernel covering the remote end is of an
interface type that does not support ARP. This patch fixes this
problem by providing a hint to the kernel routing code, which
indicates the prefix route instead of the PPP host route should
be returned to the caller. Since a host route to the local end
point is also added into the routing table, and there could be
multiple such instantiations due to multiple PPP links can be
created with the same local end IP address, this patch also fixes
the loopback route installation failure problem observed prior to
this patch. The reference count of loopback route to local end would
be either incremented or decremented. The first instantiation would
create the entry and the last removal would delete the route entry.

MFC after:	5 days
2009-12-30 21:35:34 +00:00
Ed Schouten
ca25fa25db Let umount build with -Wold-style-definition. 2009-12-30 06:36:42 +00:00
Colin Percival
07759af5eb Add undocumented 'portsnap alfred' command, which runs (fetch|cron)
based on whether fd 0 is a terminal, and then runs (extract|update)
based on whether ${PORTSDIR} exists.

Requested by:	alfred
MFC after:	1 month
2009-12-30 06:28:47 +00:00
Ed Schouten
10bc3a7f42 ANSIfy almost all applications that use WARNS=6.
I was considering committing all these patches one by one, but as
discussed with brooks@, there is no need to do this. If we ever
need/want to merge these changes back, it is still possible to do this
per application.
2009-12-29 22:53:27 +00:00
Ed Schouten
7b4f22d5ed Add missing `void' keywords. 2009-12-29 22:33:53 +00:00
Edward Tomasz Napierala
871130f516 Remove extra space introduced by the previous commit.
Submitted by:	rwatson
2009-12-29 20:30:50 +00:00
Edward Tomasz Napierala
ee00619105 Remove pppd and SLIP-related stuff. 2009-12-29 20:15:23 +00:00
John Baldwin
c34169d468 Use reallocf() to simplify some logic.
MFC after:	2 weeks
2009-12-29 15:48:04 +00:00
Antoine Brodin
13e403fdea (S)LIST_HEAD_INITIALIZER takes a (S)LIST_HEAD as an argument.
Fix some wrong usages.
Note: this does not affect generated binaries as this argument is not used.

PR:		137213
Submitted by:	Eygene Ryabinkin (initial version)
MFC after:	1 month
2009-12-28 22:56:30 +00:00
Xin LI
7f471a3289 Make umount(8) WARNS=6 clean:
- Cast delimiter width to integer [1]
 - Solve name conflicts against system header
 - Constify parameters to avoid qualifier conflict

PR:		bin/140017 [1]
Submitted by:	Ulrich Spörlein <uqs spoerlein net> [1]
MFC after:	1 month
Sponsored by:	iXsystems, Inc
2009-12-28 17:57:37 +00:00
Edward Tomasz Napierala
6fd04c3a67 Don't refer to pppd(8). 2009-12-28 09:37:33 +00:00
Doug Barton
81ef4483d0 Update the "-l or -r" usage to better conform to the standard
Submitted by:	ed
2009-12-27 23:15:23 +00:00
Doug Barton
767239710b Update the "-l or -r" usage to better conform to the standard
Submitted by:	ed
2009-12-27 23:13:18 +00:00
Ed Schouten
41477e05db Let rwhod use libulog.
I am not planning on providing a mechanism tot stat() the database files
directly. The disadvantage of this, is that rwhod will now be a little
bit more heavy than it used to be. It normally used to fstat() the file
descriptor to see whether the file had changed, but this is now
impossible to implement, meaning we have to parse the entire utmp file
each 180 seconds.

This is probably not an issue on modern 16-way servers, but if it turns
out to be a problem, we'll think of something.
2009-12-27 21:14:55 +00:00
Dmitry Morozovsky
a55743484e To remove a server, one should use double backslash, and half of them
are eaten by shell.  Fix this.

MFC after:	2 weeks
2009-12-27 16:00:17 +00:00
Doug Barton
f121ab859c Further improve the description, and bump Dd. 2009-12-27 03:43:19 +00:00
Ed Schouten
444999a314 Several refinements to libulog's API.
- Only set the fields in the ulog_utmpx structure that are valid for the
  command in question. This means that strings like "shutdown" or "~"
  are not visible to the user anymore.
- Rename UTXF_* to UTXI_*, indicating the indexation, instead of using
  the `antique' filename. If we ever get rid of utmp, it makes little
  sense calling it by its old name.
2009-12-26 22:36:05 +00:00
Ed Schouten
918592df59 Disable the unneeded inclusion of <utmp.h>.
The utmp code in systime.c is not enabled, so including <utmp.h> has no
effect in our setup. This makes it a little easier for me to migrate to
<utmpx.h>.

Approved by:	roberto
2009-12-26 18:32:35 +00:00
Robert Watson
4d2280e883 Fix wake(8) synopsis to make it clear that at least one lladdr is required
as an argument.

Submitted by:	Marc Balmer <marc@msys.ch>
MFC after:	3 days
2009-12-26 18:03:16 +00:00
Christian Brueffer
9f5f5b1051 Provide a better short description and fix SEE ALSO section entries. 2009-12-25 09:58:19 +00:00
Alexander Motin
851b967a27 Make diskinfo report disk stripe size and offset. It should help users to
make file systems optimally aligned and tuned for better performance.
2009-12-24 21:39:30 +00:00
Ed Schouten
2734cf8c82 Let syslogd use utmpx.
Because strings are guaranteed to be null terminated, there is no need
for excessive copying of strings, such as the line name.
2009-12-24 18:05:33 +00:00
Ed Schouten
71713ba2e1 Let the snmp_hostres module use utmpx.
Approved by:	harti
2009-12-24 17:55:47 +00:00
Ruslan Ermilov
a13f319046 apm(8) is no longer linked to zzz(8), catch up.
(Fixes "zzz" clash in the whatis(1) database.)
2009-12-22 14:21:08 +00:00
Edwin Groothuis
1993d7fb07 MFV of tzdata2009t, r200831
zic:
- Fix URL / reference to Calendrical Calculations: Third Edition

libc/stdtime:
- Fix typo in tzfile.5 (no changes in our part)

MFC after:	1 week
2009-12-22 11:17:10 +00:00
Gavin Atkinson
484b7a091f Grammar and minor tweaks to powerd(8) man page.
PR:		docs/133186
Approved by:	ed (mentor)
MFC after:	2 weeks
2009-12-21 22:56:06 +00:00
Doug Barton
ee55fdb8fa By popular request, execute rc.d scripts in the same environment
as they are at boot time.

Original concept submitted by:	ume
2009-12-21 20:32:04 +00:00
Xin LI
f65917cdc3 Don't consider non-existence of a PID file an error, we should be able
to proceed anyway as this most likely mean that the process has been
terminated.

PR:		bin/140397
Submitted by:	Dan Lukes <dan obluda cz>
MFC after:	1 month
2009-12-21 20:12:01 +00:00
Xin LI
18814e5069 Add support of using environment variable BURNCD_SPEED to specify
recodring speed.

PR:		bin/140530
Submitted by:	Alexander Best <alexbestms wwu.de>
MFC after:	1 month
2009-12-21 19:27:52 +00:00
Ruslan Ermilov
c409ce41b4 Don't hide an error if the initial attempt to program a watchdog from
within watchdogd(8) fails.  This is also consistent with watchdog(8).
2009-12-21 15:50:37 +00:00
Doug Barton
3d48282768 The service command is an easy interface to the rc.d system.
Its primary purpose is to start and stop services provided by
the rc.d scripts, however it can also be used to list the scripts
using various criteria.
2009-12-20 01:34:12 +00:00
Doug Barton
d90331f910 Fix a problem with how mergemaster handles the hard links for /.cshrc
and /.profile. The problem is that install(1) will unlink the old file
before it installs the new one, which means that in the best case we
have to compare the changes for the old file twice.

So, change the logic to first test to see if the link exists, then
install the file. Then if the link was there and we're using -i, just
create the link in /root and be done with it. Otherwise display the
message to the user and give them the option.

Because we are now sorting things before doing the comparison we can
know conclusively that the files in / should be the sources, and the
files in /root will be the targets, so adjust the paths accordingly.

While I'm here, split a too-long error message into two lines and
just return at the end of handling these files instead of setting
the variable that says "do nothing" and then returning at the end
of the function anyway.
2009-12-19 05:20:26 +00:00
Doug Barton
98e47f9dfe Fix an indentation issue, no functional changes 2009-12-19 01:32:34 +00:00
Doug Barton
bdeda2817b In the places where find is used that the user may see the results,
first pipe it to sort so that order of processing will be deterministic
and like things will be grouped together.
2009-12-19 01:30:45 +00:00
Ollivier Robert
09d432fc4a ntpd 4.2.4p8 is now in the tree, ntptrace is dead RIP.
Security:	CVE-2009-3563
2009-12-15 14:59:58 +00:00
Hiroki Sato
f96264e375 - Fix main() to use two separated sockets for the two transports
when "-P port" is specified.  It invoked svc{tcp,udp}_create()
  for only one of the two allocated sockets, and prevented the
  TCP socket from binding to as the result.

- Use TI-RPC functions and handle sockets in a
  transport-independent way.  At this moment only AF_INET ("udp"
  and "tcp") is supported because others need rewrites of ACL
  handling and yp clients.

- Add '-h addr' to specify addresses to bind to.

- Convert _msgout() to use variable argument lists and remove
  asprintf() for error strings.

- Remove register storage class specifier.

Discussed with:	kuriyama
MFC after:	1 week
2009-12-13 15:19:01 +00:00
Xin LI
105215075a We use gmt2local code from tcpdump and gnuc.h is no longer being used
there, so remove this dummy header.
2009-12-13 04:08:04 +00:00
Jamie Gritton
4576bbe233 Don't free jail parameter values after printing them - jail_param_get
expects them to be there for the next jail in the list.

PR:		bin/141359
MFC after:	1 week
2009-12-12 21:59:30 +00:00
Doug Barton
1b2aeedc64 Over time things that used to be files/directories/links can change
to something else. So add code to detect when things don't match and
give the user choices about how to fix it.

If we're using -P and something in the above check needs to be moved
we need to have the directory there for it, so create it at the
beginning and delete empty versions of it at the end.

The case where something used to be a file or link and now is supposed
to be a directory (e.g., /etc/security) is especially dangerous, so
make failure to install a necessary directory in $DESTDIR a fatal error.
2009-12-12 02:19:41 +00:00
Doug Barton
044823bee6 Simplify handling of MTREEFILE relative to DESTDIR
Make the message about a missing MTREEFILE combined with -U
more informative
2009-12-11 23:03:35 +00:00
Ed Schouten
b486f60642 Port lastlogin(1) to libulog.
Just use ulog_getutxuser() to obtain lastlog records or ulog_getutxent()
to browse through all of them.
2009-12-09 20:05:37 +00:00
Ed Schouten
6896e699cd Don't let sysinstall depend on <utmp.h>.
Looking at the other entries, I suspect we must also reserve one
terminating byte, so I'm using UNAME_FIELD_LEN - 1, not UNAME_FIELD_LEN.
2009-12-09 19:46:56 +00:00
Ed Schouten
f449291b33 Don't depend on <utmp.h>.
MAXLOGNAME seems more applicable in this case, because UT_NAMESIZE
refers to the username field in utmp files, which is clearly unrelated
to repquota(8).
2009-12-06 01:29:49 +00:00
Ed Schouten
41d6f23028 Make pw(8) build without <utmp.h>.
The size of the username record in utmp files should not influence the
maximum username length. Right now ut_user/ut_name is big enough, so in
this case it's dead code anyway.
2009-12-06 01:27:28 +00:00
Shteryana Shopova
1753369083 Make sure enough memory is allocated for a struct pft_entry when
refreshing the list of pf tables.

OKed by:	philip
MFC after:	1 week
2009-12-05 13:45:21 +00:00
Jun Kuriyama
8fbf071375 - In ypproc_all_2_svc(), yp_fork() is called only when !debug case.
So _exit() in the bottom of this function should be called with the
  same case.
2009-12-04 14:12:37 +00:00
Jun Kuriyama
4293e80feb - Replace magic number with YPOLDVERS macro (which may be missed in
r14262).
2009-12-04 14:08:57 +00:00
Edward Tomasz Napierala
f32534450f Yet another cosmetic fix. 2009-12-03 20:06:03 +00:00
Edward Tomasz Napierala
1f5dd95b20 Cosmetical fixes. 2009-12-03 20:02:26 +00:00
Edward Tomasz Napierala
91c72a9ad2 Cosmetical fixes. 2009-12-03 19:59:27 +00:00
Edward Tomasz Napierala
639e19ec07 Description of steps required to setup NFSv4 server is in nfsv4(4);
add reference to exports(5), since that's the obvious starting point
for searching for this.
2009-12-03 19:16:40 +00:00
Colin Percival
a235643007 Disable SSL renegotiation in order to protect against a serious
protocol flaw. [09:15]

Correctly handle failures from unsetenv resulting from a corrupt
environment in rtld-elf. [09:16]

Fix permissions in freebsd-update in order to prevent leakage of
sensitive files. [09:17]

Approved by:	so (cperciva)
Security:	FreeBSD-SA-09:15.ssl
Security:	FreeBSD-SA-09:16.rtld
Security:	FreeBSD-SA-09:17.freebsd-udpate
2009-12-03 09:18:40 +00:00
Jun Kuriyama
ce8ad96abe - New style of jail(8) usage requires "-c" argument to create a jail.
Reviewed by:	jamie
2009-11-26 03:26:59 +00:00
Attilio Rao
7a7043c787 Avoid sshd, cron, syslogd and inetd to be killed under high-pressure swap
environments.
Please note that this can't be done while such processes run in jails.

Note: in future it would be interesting to find a way to do that
selectively for any desired proccess (choosen by user himself), probabilly
via a ptrace interface or whatever.

Obtained from:	Sandvine Incorporated
Reviewed by:	emaste, arch@
Sponsored by:	Sandvine Incorporated
MFC:		1 month
2009-11-25 15:12:24 +00:00
Jaakko Heinonen
89834b119e Unify fifolog_writer usage printout with fifolog_create and
fifolog_reader.

Approved by:	trasz (mentor)
2009-11-17 17:38:41 +00:00
Jung-uk Kim
2272d05019 Merge ACPICA 20091112. 2009-11-16 21:47:12 +00:00
Kirk McKusick
708a2897f1 Convert quotaon/quotaoff to use the new quotafile functions. 2009-11-16 18:50:51 +00:00
Attilio Rao
1262810177 Collapse devinfo_state_t with device_state_t in order to avoid a
structure replication and improve manteneability.

Reviewed by:	jhb, imp
Tested by:	Riccardo Torrini <riccardo at torrini dot org>
2009-11-15 16:44:43 +00:00
Ed Schouten
4b2361f811 Convert syscons on i386 to TERM=xterm.
TEKEN_XTERM is now gone. Because we always use xterm mode now, we only
need a TEKEN_CONS25 switch to go back to cons25.
2009-11-13 11:28:54 +00:00
Ed Schouten
e42fc36867 Switch the default terminal emulation style to xterm for most platforms.
Right now syscons(4) uses a cons25-style terminal emulator. The
disadvantages of that are:

- Little compatibility with embedded devices with serial interfaces.
- Bad bandwidth efficiency, mainly because of the lack of scrolling
  regions.
- A very hard transition path to support for modern character sets like
  UTF-8.

Our terminal emulation library, libteken, has been supporting
xterm-style terminal emulation for months, so flip the switch and make
everyone use an xterm-style console driver.

I still have to enable this on i386. Right now pc98 and i386 share the
same /etc/ttys file. I'm not going to switch pc98, because it uses its
own Kanji-capable cons25 emulator.

IMPORTANT: What to do if things go wrong (i.e. graphical artifacts):

- Run the application inside script(1), try to reduce the problem and
  send me the log file.
- In the mean time, you can run `vidcontrol -T cons25' and `export
  TERM=cons25' so you can run applications the same way you did before.
  You can also build your kernel with `options TEKEN_CONS25' to make all
  virtual terminals use the cons25 emulator by default.

Discussed on:	current@
2009-11-13 05:54:55 +00:00
Ed Schouten
c8f1c81702 Add a new flag to vidcontrol, -T, that allows terminal mode switching.
This will make it more easy for people to experiment with TERM=xterm.
Instead of echoing these strange escape sequences, I can just instruct
them to run `vidcontrol -T xterm'.
2009-11-11 08:39:57 +00:00
Dag-Erling Smørgrav
151a18cd10 Remove a bunch of code used to detect SMP on ((i386 && !pc98) || amd64) and
offer to install an SMP kernel.  The way this worked was: on supported
platforms, code to read ACPI tables and BIOS MP tables was compiled into
sysinstall, and if an SMP kernel config was present in the source tree when
sysinstall was built, code that called it was also compiled.  Since we
haven't had SMP kernel configs in years, the latter was never compiled and
the former never ran.

This only removes dead and unreachable code; it does *not* remove the NCpus
variable, nor the code that sets it to 1, nor the code that asks the user to
select a kernel from a list.

Discussed with:	re@, randi@ and others
2009-11-10 10:34:44 +00:00
Xin LI
59bf36c3a7 Set umask to 0x077 instead of the default. This prevents non-root user
from reading crashinfo output, which could contain some sensitive
information.

Reviewed by:	jhb
MFC after:	1 week
2009-11-03 09:17:23 +00:00
Andrew Thompson
e975f97cd0 Add more verbose output when dumping the configuration descriptor.
Submitted by:	Hans Petter Selasky
2009-11-02 23:50:12 +00:00
Edwin Groothuis
1f72185627 MFV of r198828, tzcode2009q
- Cleanup unnecessary local variables in zdump.
- Fix man-page

MFC after:	1 week
2009-11-02 23:02:11 +00:00
Christian Brueffer
cf6c5eebe7 Use our canonical .Dd format.
Submitted by:	Ulrich Spoerlein
2009-11-02 12:35:38 +00:00
Christian Brueffer
94b7ebd774 Expand DESCRIPTION and a basic EXAMPLES section.
PR:		139605
Submitted by:	Warren Block <wblock@wonkity.com>
MFC after:	1 week
2009-11-01 11:39:07 +00:00
John Baldwin
c5229b9d2b Include the output of the ddb(4) capture buffer.
Submitted by:	Mikolaj Golub  to my trociny of gmail
MFC after:	3 days
2009-10-29 13:45:33 +00:00
Colin Percival
207ec3a836 Don't leak a file descriptor when ejecting a CDROM.
Submitted by:	Ronald Klop, trhodes
Note to self:	don't do commits while half-asleep
2009-10-26 23:24:59 +00:00
Colin Percival
dddeaa47e4 Eject CDROM after installation if used as source media.
Submitted by:	randi
MFC after:	1 month
2009-10-26 06:51:20 +00:00
Edwin Groothuis
b5f58d7778 - Add support for chrooted installs.
- Add examples to the man-page.

MFC after:	1 week
2009-10-21 20:55:04 +00:00
Rink Springer
c8c45602aa Introduce 'netDev=ANY' support for scripted (install.cfg) installs, which results in the first ethernet interface with physical link being selected.
While here, fix a minor typo causing an 'if' to be missed.

Submitted by:	randi
2009-10-21 11:10:34 +00:00
Kirk McKusick
4e717eeafc Claen up format when doing non-humanized output. 2009-10-20 17:50:27 +00:00
Kirk McKusick
88c01c7739 Update to work with quotafile functions in -libutil. 2009-10-20 16:46:39 +00:00
Edwin Groothuis
ada5f18a1b Instead of having to know which timezone was picked last time, you
now can run "tzsetup -r" which will reinstall the last choice. This
data is recorded in /var/db/zoneinfo.

MFC after:	 1 week
2009-10-20 06:54:31 +00:00
Kirk McKusick
0cf50fd7dc Update to work with quotafile functions in -libutil.
Add -h flag to provide humanized output.
2009-10-20 05:40:51 +00:00
Edwin Groothuis
b89269048d Make the usage of the default zoneinfo file to install clearer.
MFC after:	 1 week
2009-10-19 21:37:31 +00:00
Edwin Groothuis
08c7e8c879 When tzsetup is run as non-root and the "CMOS clock question on
UTC" is answered as No, it would abort without properly ending the
dialog session.

MFC after:	 1 week
2009-10-19 21:24:19 +00:00
Jung-uk Kim
f556842ef6 Merge ACPICA 20091013. 2009-10-19 16:12:58 +00:00
Ed Schouten
5fd658af94 Don't forget to increment the man page date.
Reported by:	bz
2009-10-18 20:33:24 +00:00
Ed Schouten
f19fa944e6 Fix a typo in the jail(8) manpage.
Submitted by:	Jille Timmermans <jille quis cx>
MFC after:	1 week
2009-10-18 19:50:15 +00:00
Ed Maste
6ff4bdaef5 Correct typo: thetime -> the time
PR:		docs/139447
Submitted by:	Guido Falsi  mad at madpilot dot net
2009-10-13 12:56:23 +00:00
Jaakko Heinonen
6e7b6303ba When run() returns an error, print the error message also in
non-interactive mode. Previously error messages were printed only in
interactive mode.

PR:		bin/124517
Approved by:	trasz (mentor)
MFC after:	1 month
2009-10-07 13:25:22 +00:00
Jilles Tjoelker
072a126d12 Fix using lp(1) without the new -t option after r194171.
PR:		standards/129554
Tested by:	Steve Kargl
MFC after:	1 week
2009-09-29 21:28:32 +00:00
Colin Percival
d23dc1ee5f Special-case "-r X" where X is [0-9.]+ to mean "-r X-RELEASE".
Tripped over by:	too many people to count
MFC after:	1 month
2009-09-29 16:26:09 +00:00
Dag-Erling Smørgrav
6cfc1c1e18 type / format fixup 2009-09-27 17:33:26 +00:00
Jung-uk Kim
71f99e637a Copy apm(4) emulation from sys/i386/acpica/acpi_machdep.c and
install apm(8) and apm_bios.h on amd64.
2009-09-27 14:00:16 +00:00
Dag-Erling Smørgrav
0fbc5fbedf Sync with head 2009-09-25 22:45:59 +00:00
Ed Schouten
b05f9c86d1 Make the keyboard layer Unicode aware.
Just take keyent_t to use an u_int to store the Unicode codepoints.
Unfortunately the keymap is now too big to be loaded using an ioctl
argument, so change the ioctl to pick a pointer.

This change breaks kbdcontrol ABI. It doesn't break X11, because X11
doesn't do anything with syscons keymaps. It just switches the device
out of K_XLATE.

Obtained from:	//depot/user/ed/newcons/...
2009-09-19 17:56:26 +00:00