Commit Graph

10918 Commits

Author SHA1 Message Date
joerg f9c779de17 Add a check for duplicate keys. The check is run once and quadratic in
the hash collision chain length, which is expected to be fairly low.
2010-03-03 01:55:04 +00:00
gdt 324332f31f Log successful and unsuccessful attempts to change passwords, via -l
or pam, to ease IT audit guideline compliance.  Patch from Richard
Hansen of BBN in private mail.

Proposed on tech-kern with positive comments, except a suggestion I
didn't implement:

A possible future enhancement is refraining from logging if the old
password is empty, as some people abort password changing that way.
However, it's not clear if this complies with most guidelines that
require password change logging, and at first glance that appears to
be a fairly difficult change.
2010-03-02 16:19:13 +00:00
joerg 97b3b0515b Fix a comment. 2010-03-01 21:46:58 +00:00
roy 9033c3cfe7 Sync against new ld.elf_so 2010-02-27 11:17:05 +00:00
mbalmer 945771eda0 DEL is 0x7F, not 0xFF. From FreeBSD via OpenBSD. 2010-02-27 10:45:23 +00:00
christos f0e3fdff97 matt wants the ping timeout to be 1sec 2010-02-26 22:44:17 +00:00
christos 2bd4c53fca PR/42207: YAMAMOTO Takashi: If the portmapper (rpcbind) is not running, eject
takes 2 minutes to timeout. Add a ping the portmapper function that times out
after 5 seconds.
2010-02-26 20:18:37 +00:00
pooka bc1cf39b94 Add -h, which makes output of bytes counts "humanized" (e.g. -bih)
(netstat had -h some 15 years ago, but since then it has been just
a fancy way of calling usage())
2010-02-24 11:00:27 +00:00
skrll 4931e61023 Mark each object as printed as visited and then print.
Fixes PR/42811.

As a side effect the libraries are printed in, imo, a better order.
2010-02-23 08:23:24 +00:00
roy fde317d2b1 libterminfo can now compile a single terminfo description which allows
$TERMINFO to be a terminfo description as well as a file reference.

This enables the user to modify the terminfo description on read-only
media.
2010-02-22 23:05:39 +00:00
joerg 87faf7cb4f \\ -> \e 2010-02-22 19:20:33 +00:00
pgoyette 3360c946f9 One more time - do this correctly.
Thanks, joerg.
2010-02-20 06:20:46 +00:00
pgoyette 4b2f1808e2 Wrap the include of sys/endian.h in #ifdef HAVE_SYS_ENDIAN_H to avoid
build issues on systems that don't have a sys/endian.h

Pointed out by joerg@
2010-02-20 06:15:06 +00:00
pgoyette 237e56a5c8 Since tic is a host tool, we need to include host system header to get
definitions of le16dec() and le16enc().

Solves PR bin/42747 from Henning Petersen
2010-02-20 06:08:01 +00:00
tnn 0846a7629f Merge the following revisions from OpenBSD to let sed(1) handle
arbitrarily long lines (closes our PR bin/42261).
openbsd/usr.bin/sed/extern.h 1.5
openbsd/usr.bin/sed/main.c 1.13-1.15
openbsd/usr.bin/sed/misc.c 1.8
openbsd/usr.bin/sed/compile.c 1.25-1.28
openbsd/usr.bin/sed/defs.h 1.4
2010-02-19 16:35:27 +00:00
tron a1573270c3 Report the number of characters, not the number of bytes in the
longest line.

Problem pointed out by YAMAMOTO Takashi on "tech-userlevel" mailing list.
2010-02-19 11:15:23 +00:00
joerg 149eb58444 Only print the "Archive: xxx" header if not in extract-to-stdout mode. 2010-02-18 15:51:57 +00:00
wiz 8f657e21de Fix typo (specifed -> specified). 2010-02-18 14:00:39 +00:00
wiz eedc241ad5 New sentence, new line. Add EXIT STATUS section and use .Ex.
Fix macro argument abuse.
Use Aq instead of \*[Lt]\*[Gt].
2010-02-18 13:14:51 +00:00
tron 10109091b2 Add support for "-L" option (longest line) as present in the GNU and
FreeBSD version of "wc".

No objections on "tech-userlevel" mailing list.
2010-02-18 10:43:50 +00:00
pooka 7547791dd3 Fix off-by-one (config -x works again) and improve editing artifacts
(actually the whole "config -x must be used alone" change was made
unnecessary along the way.  cest la vie).
2010-02-13 22:57:03 +00:00
roy 5176b19781 Report when using internal database. 2010-02-11 14:38:43 +00:00
wiz a2542d1a41 Oxford serial comma. 2010-02-11 13:44:14 +00:00
roy b164f98a45 Change -S to output C structures to make life easier. 2010-02-11 13:09:57 +00:00
roy 81c1c09bfc Report if using internal database or not. 2010-02-11 08:46:18 +00:00
wiz 66fbc76fcb Sort options (standard order is 0-9AaBbCc...). 2010-02-11 07:00:46 +00:00
roy 55a396b95f tic -S now outputs the specified terminal names and compiled descriptions
as C strings so we can embed them into libterminfo.
2010-02-11 00:24:46 +00:00
roy eae295f613 We need to cap reset_file/init_file. 2010-02-10 10:34:59 +00:00
roy 8cfe7bba8c Tidy defs. 2010-02-10 10:34:31 +00:00
roy 416b512efb Constify cat argument and tidy. 2010-02-10 10:33:45 +00:00
wiz 8e35c759e7 Fix typo in comment. 2010-02-09 23:05:16 +00:00
wiz 91440662bd Bump date for previous. 2010-02-09 14:25:39 +00:00
drochner ec10ab0177 remove agitation that od(1) was deprecated -- it is still POSIX 2010-02-09 14:06:37 +00:00
eeh 5173fff056 Some bugfixes and enhancements. Support for case .. of and fix calculation
of branch offsets.
2010-02-08 20:14:55 +00:00
he 76d4444c78 When using -lcurses, you also need -lterminfo.
This fixes the build for sun2, and also builds with LDSTATIC=-static,
since archive libraries don't record inter-library dependencies.
2010-02-06 23:45:24 +00:00
dholland 607923e4ca Improve the error message that results when you have a multi-variable .for
and the substitution list doesn't divide evenly.
2010-02-06 20:37:13 +00:00
enami 47e571f2ea Don't touch past the end of allocated region. It results segmentation
violation.
2010-02-05 21:58:41 +00:00
roy 2bb24c0bfc Fix year. 2010-02-05 16:54:11 +00:00
roy 5f630912a5 Fix infocmp when both -a and -x are given as arguments. 2010-02-05 16:43:46 +00:00
roy 71dfbe1cc5 Note that -a no longer sets -x. 2010-02-05 16:36:09 +00:00
he 29cb6e1f41 More adaptation for ports where char is unsigned char. 2010-02-05 14:40:07 +00:00
roy ae351fab5b Store the aliases against the entry, so that infocmp can reproduce them.
Handy for creating smaller terminfo databases.
2010-02-05 12:31:56 +00:00
roy 461cb40b76 Make our unsigned char ports happy. 2010-02-05 10:10:04 +00:00
wiz 2df103a0fe Sort SEE ALSO. New sentence, new line. Whitespace fix. 2010-02-04 09:48:35 +00:00
pooka ec78f798c7 ... aaand make the emit-order slightly more sensible for ioconf.c to
actually work again.
2010-02-03 21:32:27 +00:00
pooka e239742f9b Introduce experimental support for ioconf-only configuration files.
This is done by giving the "ioconf" keyword in the config file.
As a result, config produces only ioconf.c and locators.h.  Currently,
only "monolithic" configurations with the device path starting from
root are supported.  Eventually, the goal is to support a local
root in the input file from any point along the device tree using
files.* in our kernel tree.  This will make autogenerating the
config glue for device modules possible instead of having to write
it by hand like is currently required (yes, it sounds simple to
implement, but ...).

reviewed by cube.
(the next part will demand major discussions with you, so prepare ;)
2010-02-03 21:00:49 +00:00
roy 588d0cb499 getent cannot report on termcap as we now use terminfo. 2010-02-03 18:11:18 +00:00
wiz 91dad5b171 Use .Ex for EXIT STATUS. 2010-02-03 15:51:51 +00:00
wiz fcf135c013 Use Ex for EXIT STATUS section. Put Ns on same line as previous,
to make clearer what happens.
2010-02-03 15:51:09 +00:00
roy 98eb889579 Userland now builds and uses terminfo instead of termcap.
OK: core@, jdc@
2010-02-03 15:34:37 +00:00
roy 4ca00e00d8 Import my terminfo implementation.
This uses the ncurses terminal definitions.

OK: core@, jdc@
2010-02-03 15:16:32 +00:00
mbalmer 0f58fac97e fix language 2010-01-28 14:12:11 +00:00
jnemeth c14fd5dcde first Apple Macintosh, 1984 2010-01-24 22:56:12 +00:00
dholland e5f6e006f6 punctuation 2010-01-24 20:13:28 +00:00
pooka 830034140c Add static to packdevi() like the local prototype says. 2010-01-21 18:06:38 +00:00
simonb dea9b0fedb Use TAB as a separator to be consistent with the rest of this file. 2010-01-21 01:59:09 +00:00
jnemeth a485eea416 add Buzz Aldrin, second man on the moon 2010-01-20 22:56:59 +00:00
ginsbach 2dfe7f3174 - Fix bug where -o outfile fails when outfile does not exist. Pointed
out by Tony Finch.
2010-01-20 19:02:42 +00:00
dholland dcf56c99e1 Remove some leftover bits of tn3270 that got left behind. 2010-01-17 04:15:41 +00:00
christos a6b956aa6c - we don't need stdbool.h anymore.
- the previous fix for the negative index logic was wrong, fix it.
2010-01-16 21:26:59 +00:00
roy 8dafc5727f Remove tn3270 from base system.
If anyone really needs it then it can be put into pkgsrc.
Importing c3270 into pkgsrc is probably a better option though.
2010-01-16 15:34:22 +00:00
mbalmer 8f42635938 fix wording:
instead of the a file -> instead of a file
2010-01-16 08:50:29 +00:00
joerg 642cfb40e9 Use .%U instead of .%O for URLs. 2010-01-15 19:39:10 +00:00
christos aa0d683311 Add a list of functions where we usually don't care about their return
code. Can be bypassed by -hh
2010-01-14 16:58:27 +00:00
christos d449716afd error message cleanup
- 1 -> EXIT_FAILURE
- fprintf(stderr, -> warnx(
- better warning messages
2010-01-12 14:45:31 +00:00
christos b8afdde726 - 1 -> EXIT_FAILURE
- avoid assertion firing when hitting ^D in CC: line.
2010-01-12 14:44:24 +00:00
christos 533d2abbab - 1 -> EXIT_FAILURE
- preallocate child struct, since the signal handler can be called before
  wait_child, and we cannot allocate a child struct there. there is a signal
  race still here if the program exits and the signal handler is called before
  we allocate the struct.
2010-01-12 14:43:31 +00:00
lukem 7858a04d0e rename argument from "bool" to "val" 2010-01-12 06:50:04 +00:00
christos 039ab08b25 fix hex double parsing. 2010-01-11 16:28:06 +00:00
dholland ea99ee8691 fix some typos 2010-01-11 09:03:46 +00:00
joerg 06c042e9bc Plug a memory leak. From Igor Zinovik. 2010-01-10 01:10:16 +00:00
mbalmer f5e8307179 When restoring files, use the mode, not the filetype, for the mode.
From FreeBSD (r201630)
2010-01-09 09:27:42 +00:00
kiyohara 5a06e069fd Fix a bug.
always mkdir for 'objs' and 'objdir' when NEW_TOOLCHAIN.
2010-01-09 06:37:57 +00:00
jnemeth 0ec6aab4dd add Stephen Hawking, 68 today 2010-01-09 01:24:18 +00:00
sjg 03c533138a We need to have set curdir before calling Dir_FindHereOrAbove().
We can call getcwd again if -C is used.
2010-01-04 17:05:25 +00:00
dsl 99db72360c Remove some sign compare warnings. 2010-01-02 16:08:20 +00:00
christos f550d323b5 don't repeat the word login twice (syslog prepends the program name login:) 2009-12-29 20:15:15 +00:00
christos c56d2f766e kill the space in address formatting to match what other daemons do. 2009-12-29 19:27:43 +00:00
christos d74e5fa896 PR/42540: Ed Ravin: /usr/bin/login does not log normal logins, and does not
log ip addresses.
- Factor out the common code in login.c and login_pam.c into common.c
- Always log a login event
- Check passed in sockaddr against the one from getpeername(2).
2009-12-29 19:26:13 +00:00
tsutsui ba6eca2794 Use %zu for size_t, not %zd. 2009-12-19 10:27:13 +00:00
hubertf f092da9a2f Conditionalize the yyinput/input() function definition the same way
as it's always been done in the prototype.

OK christos@
2009-12-15 22:46:04 +00:00
mrg f4f977dbc5 make this actually build on mips64. 2009-12-15 04:06:43 +00:00
uebayasi ad7af028ce Fix typo in previous. 2009-12-14 17:16:12 +00:00
uebayasi 54fa447685 Merge from matt-nb5-mips64; adapt to vaddr_t / vsize_t format specifiers. 2009-12-14 14:29:09 +00:00
uebayasi 338fe7370e Adjust size_t format specifiers for mips64e[bl]. 2009-12-14 14:11:32 +00:00
uebayasi fce6fcbb2c Teach crunchide(1) that mips64e[bl] is 64-bit ELF. 2009-12-14 14:01:10 +00:00
christos 3ca6a849fc use .ORDER to avoid race 2009-12-14 05:23:39 +00:00
dholland 10a5ee8495 Don't attempt to read or write ~/.lesshst if it's not a regular file
or a symlink to a regular file. Previously, symlinking to /dev/null
would cause less to trash /dev/null if run with sufficient privileges,
as seen in PR misc/42237.

While the official way to disable .lesshst is to set an environment
variable, that is problematic in some cases, such as single-user mode.
A safer way to prevent even an unpatched less from writing anything
out is to mkdir ~/.lesshst.
2009-12-14 03:58:27 +00:00
matt 82d396ea31 Merge from matt-nb5-mips64 2009-12-14 00:43:05 +00:00
matt c31d577a8c Merge from matt-nb5-mips64
Teach lint about mips64
2009-12-14 00:42:06 +00:00
mrg 118cb193d7 - adjust the logic for compat ldd: add an elf32_compat module and arrange
for mips64 to build this with MLIBDIR set to o32
- make mips64 ldd call elf32_compat_ldd as well
- make mips64 elf64 set MLIBDIR to 64
- don't need ld.elf_so's Makefile.ld32 files anymore (they are going away
  soon anyway)

tested on amd64 and sparc64, and an earlier version tested on mips64.
2009-12-13 08:50:56 +00:00
uebayasi afecdcdcbc Use $GENCMD to generate misc.[ch]. Carefully quote strings. 2009-12-11 16:10:56 +00:00
plunky 75847ce3f8 accept uppercase hex digits when parsing a provided key 2009-12-10 18:57:31 +00:00
wiz 3d8b25a8ff Fix problem of reporting wrong matches noted in PR 41945 by using a patch
provided by Robert Elz in that PR.
2009-12-08 13:49:08 +00:00
mbalmer 74f49bc48d s/the the/the/ 2009-12-08 09:46:01 +00:00
mbalmer 559e4d0905 make sense, s/the the/with the/ 2009-12-08 09:45:15 +00:00
uebayasi f5321e7bbf Put back the dependency of dump.c agaist misc.h. This is needed because
dump.c includes misc.h but misc.h is generated on-the-fly.

Note that dump.c is out of the makeerrnos.sh -> misc.[ch] generation rule
now.  This prevents ktruss from being unnecessarily rebuilt in rescue/.

Pointed out by enami@, thanks!
2009-12-08 02:56:37 +00:00
christos 8f7e9f408c PR/42243: Yasuoka Masahiko: Add support for "net.inet.icmp.bmcastecho" support.
Print the current status.
2009-12-07 18:48:45 +00:00
uebayasi acfaaf21f8 Correct the dependency; makeerrnos.sh generates misc.c and misc.h. dump.c
is never involved there.  Those dependency has been wrong since Rev. 1.1.
2009-12-06 14:37:36 +00:00
pooka 70d4493c77 Remove the portalfs kernel file system driver. Replace mount_portal(8)
with a version based on puffs.  User functionality remains the same.
2009-12-05 20:11:01 +00:00
plunky e16149e27c add alias for Plug'n'Play Information service UUID.
(This is sometimes used in HID devices to provide manufacturer information)
2009-12-05 16:54:13 +00:00
mrg 59c18d14fe apply a change from Xin LI <delphij@delphij.net> to avoid problems when
reading from pipes.  introduced with the multi-part bz2 fixes.
2009-12-05 03:23:37 +00:00
dsl 7828c3fe21 Add a note telling people to use the shell getopts builtin. 2009-11-28 20:36:45 +00:00
dsl e2fd1f1d18 Use shell builtin getopts instead of getopt(1).
Fixes PR/30425
2009-11-28 20:30:01 +00:00
darcy fc5c0ee967 Don't include newlines when comparing to prevent errors when lines have
characters that sort lower such as tabs.

This is a temporary fix to allow pullups to existing, supported versions
of NetBSD.  I will follow up with a version for current using the new
getline function.
2009-11-28 03:56:38 +00:00
plunky 60e7a7b128 add translation for "802.1Q" ethertype 2009-11-22 18:53:44 +00:00
wiz af753b56d3 New sentence, new line; remove trailing whitespace. 2009-11-19 06:48:37 +00:00
sjg 9772f81de8 Add .unexport - the exact opposite of .export
and .unexport-env which unexport's all previously .export'd globals
as well as clearing environ[].
Allow's sys.mk near total controll.

Reviewed by: apb
2009-11-19 00:30:25 +00:00
sjg b87966b319 PR: make.unexport
Reviewed by:
2009-11-19 00:30:24 +00:00
sjg f3c8b50aa4 Add .unexport - the exact opposite of .export
and .unexport-env which unexport's all previously .export'd globals
as well as clearing environ[].
Allow's sys.mk near total controll.

Reviewed by: apb
2009-11-19 00:30:24 +00:00
skrll 77fd7698f3 Make _rtld_pagesz of type size_t.
Fixes round_down for alpha which made ldd(1) break.
2009-11-17 18:44:33 +00:00
drochner 884c70cd50 ANSIfy, sprinkle "const" in some obvious cases 2009-11-17 18:31:12 +00:00
drochner 51f9e504fe kill a stray semicolon which made that the "-p <cmd>" option in
POSIX mode didn't work as expected
2009-11-16 19:40:17 +00:00
lukem 7f19467717 Crank version to 20090915:
* rename internal getline() to get_line() to avoid conflict with libc
* avoid NULL deref in verbose output in an error path
* improve man page markup
2009-11-15 10:03:16 +00:00
tron 87a288ba6f Don't assume that "id_t", "gid_t" and "uid_t" use the same underlying type
and use the appropriate types instead. Tested under NetBSD 5.99.22
and Darwin 10.2.0.

This should fix one of the cross-builds under FreeBSD as reported by
Rhialto on the "current-users" mailing list.
2009-11-12 10:10:49 +00:00
joerg 2ec9715635 Do not use \." for comments, always use .\". Discussed with uwe@. 2009-11-12 00:43:52 +00:00
dsl fe39abeba9 Clarify (hopefully) the description of -remove.
Fixes PR/38987
2009-11-06 21:03:12 +00:00
dsl c85c5e109a Report lines that ought to contain a ':' operator but start with a '.'
as "Unknown directive" sinze they are more likely to be .elseif (etc).
Lets me close PR/37222!
2009-11-06 20:20:56 +00:00
dsl 9e7c371385 Change enum values so that TOK_FALSE is 0 and TOK_TRUE is 1.
Use this fact to remove loads of ? : clauses.
2009-11-06 19:44:06 +00:00
joerg 2b8a053617 Retire __SCCSID. It has only archeological value now. Also retire lint
conditional around __RCSID, lint can handle that fine.
2009-11-06 18:34:22 +00:00
joerg 98712b66ed Fix __progname mess. 2009-11-06 15:13:27 +00:00
dsl ff86378d52 Allow display intervals > 25 seconds.
Fixes PR/36999
I did contemplate chaging curses - but the code is replicated and warped.
2009-11-04 21:46:24 +00:00
dsl 57843c1579 Correctly count number of chars output so that help isn't blank if the
terminal is too narrow.
Not ideal since the last command isn't shown on 80 column terminals.
2009-11-01 22:08:14 +00:00
joerg c2ab44f7a7 Always define _PATH_DIVNAME to the Unix version. Drop UNIQUE.
Fixes build on Mac OS X.
2009-10-31 23:25:04 +00:00
joerg 17c3d35d69 Only trust STRIP from environment if it is non-empty. Some packages set
STRIP in Makefiles and that makes install -s fail badly. OK apb@
2009-10-30 20:57:30 +00:00
uebayasi 4effe2d8e0 Now that YYSTYPE yyval is not global, use yylval from within yylex(). 2009-10-30 15:09:24 +00:00
joerg 0a4531336b Fix markup. 2009-10-30 01:40:45 +00:00
christos 2853bbf4b7 use %option instead of #define YY_NO_... 2009-10-29 14:49:02 +00:00
christos e2f4586574 option noinput 2009-10-29 14:37:56 +00:00
christos be9443776f option noinput nounput 2009-10-29 14:37:16 +00:00
christos 926a7cc331 option noinput 2009-10-29 14:35:25 +00:00
christos 3cd2e75890 unhook yacc 2009-10-29 01:01:17 +00:00
christos ba79df8804 put all the YY_NO in one place. 2009-10-28 22:22:44 +00:00
christos 6ed80d5bb1 no unput 2009-10-28 22:09:02 +00:00
christos cbf0b9da9a more no unput 2009-10-28 21:42:47 +00:00
christos 350212331d Handle nbtools build better. 2009-10-28 12:59:24 +00:00
christos c2261f6766 don't '#define yywrap() 1', use '%option noyywrap'. This is because the
#define is doomed to failure if --prefix is used.
2009-10-28 02:42:20 +00:00
christos a1b53986b9 unhook lex 2009-10-26 21:37:10 +00:00
christos c6ea3d2acf fix the tools build 2009-10-26 21:16:49 +00:00
christos 315c7490d2 fix compilation. 2009-10-26 21:14:18 +00:00
christos 7b2c561b05 fix prototype 2009-10-26 21:12:47 +00:00
christos f3efdb75c5 resolve conflicts. 2009-10-26 21:11:28 +00:00
christos 71dafaa1f2 Import new m4 from OpenBSD. 2009-10-26 21:08:59 +00:00
christos d79895b899 put back lex 2009-10-26 04:09:45 +00:00
christos 6beb933941 unhook old flex. 2009-10-26 01:18:19 +00:00
wiz 50a251ce93 Match directory extraction output with Infozip. 2009-10-25 20:14:50 +00:00
wiz 467a0fa1ae Bump date for uarea swap-out removal. 2009-10-21 22:18:37 +00:00
rmind 40cf6f3659 Remove uarea swap-out functionality:
- Addresses the issue described in PR/38828.
- Some simplification in threading and sleepq subsystems.
- Eliminates pmap_collect() and, as a side note, allows pmap optimisations.
- Eliminates XS_CTL_DATA_ONSTACK in scsipi code.
- Avoids few scans on LWP list and thus potentially long holds of proc_lock.
- Cuts ~1.5k lines of code.  Reduces amd64 kernel size by ~4k.
- Removes __SWAP_BROKEN cases.

Tested on x86, mips, acorn32 (thanks <mpumford>) and partly tested on
acorn26 (thanks to <bjh21>).

Discussed on <tech-kern>, reviewed by <ad>.
2009-10-21 21:11:57 +00:00
joerg 6e3add81a1 Do not try to mmap a zero length file. 2009-10-21 17:16:11 +00:00
wiz d5ecf43f6a Fix problems with SIGWINCH. From Paul Ripke in PR 42161. 2009-10-21 13:56:36 +00:00
snj 550147bd6a Remove 3rd and 4th clauses in christos' license. OK christos. 2009-10-21 01:07:44 +00:00
snj 4968c04d96 Move Eduardo Horvath's license to 2 clause. OK eeh@. 2009-10-19 18:12:37 +00:00
snj 065c5ae0d0 Move Matthias Pfaller's files to 2-clause license. OK matthias@. 2009-10-18 18:13:59 +00:00
christos 949a1d1b55 use system to parse args 2009-10-17 22:36:23 +00:00
wiz da3d98a56d New sentence, new line. Remove trailing whitespace. 2009-10-17 22:28:33 +00:00
christos ab107e386c add more features found in other unices 2009-10-17 19:05:54 +00:00
wiz a193d72dee Reflow to < 80 chars. 2009-10-16 08:09:12 +00:00
hubertf f7456856c8 Make the format for -k clearer 2009-10-15 23:12:53 +00:00
joerg 568625a8d1 Do not work around ancient groff limits with .Xo/.Xc. 2009-10-15 02:27:44 +00:00
joerg 63ec927bcc Use -compact + explicit .Pp instead of .sp with negative line length. 2009-10-15 02:26:38 +00:00
joerg 98ae2d6073 Do not use .Xo/.Xc to workaround ancient groff limits. 2009-10-14 17:44:25 +00:00
christos a49ff4deac Avoid segv on "printf '%*********s' 666", from Maksymilian Arciemowicz 2009-10-13 19:28:31 +00:00
mrg 5e3404f76c update version to today. 2009-10-11 09:17:21 +00:00
mrg 205ea56f45 avoid an overflow in suffix handling, from Xin LI <delphij@delphij.net>. 2009-10-11 07:09:39 +00:00
mrg 569ceba59d add "pack" uncompression support, from Xin LI <delphij@delphij.net> 2009-10-11 07:07:54 +00:00
mrg 628b55bb8d fix support for multi-section bzip2 files, as created by pbzip2. 2009-10-11 05:17:20 +00:00
dsl 43682b02ee If anyone is stupid enough to feed records longer than 8MB into sort, don't
sit in an infinite loop, instead eat memory until we have read 8 records.
2009-10-09 20:32:57 +00:00
dsl 41b3ada21c When we need to merge more than 16 files, do them in a hierarchy.
Reduces the amount of data written to temporary files.
The 3-level stack has to do a simple reduce after 4352 input files, for
a normal file sort this is 35GB of data or about 500 million records.
This needs about 50 open fd's - which should be ok.
Clearly the merge sort could process more input files in one go - speeding
up the sort, but at some point the number of input files would exceed
whatever limit was applied.
2009-10-09 20:29:43 +00:00
dsl 768e6fa973 Don't give merge an empty file when we detect EOF with nothing in our
buffer.
2009-10-09 20:23:19 +00:00
dsl 8b6ec7b129 long align records written to temporary files. 2009-10-07 21:03:29 +00:00
dsl 5aa782f502 When encoding numbers, we can use all 8 bits for exponent values. 2009-10-07 21:02:57 +00:00
sjg baca35f4e0 The parser used to break dependency lines at ';' without regard
for substitution patterns.  This (perhaps coupled with the
new handling of .for variables in ${:U<value>...) caused interesting
results for lines like:

.for file in ${LIST}
for-subst:       ${file:S;^;${here}/;g}

add a unit-test to keep an eye on this.
2009-10-07 16:40:30 +00:00
cegger 656e85b2f1 Mimic OSX behaviour:
On OS X it is possible to specify the manpage filename
with a full or relative path like this:

   man ./foo.5

or

   man /cd/foo/bar.1.gz

This is really helpful to view the manpage quickly while editing it.

patch presented on current-users@ and tech-userlevel@:
http://mail-index.netbsd.org/current-users/2009/10/06/msg010767.html
http://mail-index.netbsd.org/tech-userlevel/2009/10/06/msg002675.html

No objections
2009-10-07 08:30:31 +00:00
wiz ddecca9be6 Fix Dd argument (use full month names). 2009-10-06 21:39:58 +00:00
plunky 0fbc382d6d allow to specify 32-bit bluetooth short alias or full UUID strings
on the commandline.
2009-10-06 19:21:17 +00:00
cegger 58b5db465d - use EXIT_FAILURE/EXIT_SUCCESS
- whitespace nits
- ansify cleanup()/usage()
- remove pointless parenthesis on return
2009-10-06 06:43:15 +00:00
christos 7770393bf8 add type attributes in a few more places. 2009-10-03 17:09:18 +00:00
christos 3da8ec1b81 accept struct { ... } __packed name; 2009-10-03 01:35:20 +00:00
christos 17b31cc3a2 handle bit fields in packed structures. 2009-10-02 21:49:30 +00:00
christos 876a5b04b7 compute sizes by the new tsize() function. 2009-10-02 21:04:03 +00:00
christos 19f30f4ea2 fix typedef struct __packed 2009-10-02 20:45:06 +00:00
christos 2144a69bda remove debugging 2009-10-02 19:02:16 +00:00
christos 872e317461 recognize struct __packed x { }; in addition to struct x { } __packed; 2009-10-02 19:01:13 +00:00
christos f07e30ff20 change initialization from non const of regular variables to c99 instead of
gnu since c99 now has it.
2009-10-02 18:17:16 +00:00
christos bb531790dc understand __attribute__((__packed__)) and __packed. 2009-10-02 15:03:45 +00:00
wiz 3c9c8e60ab Remove trailing whitespace. 2009-10-02 07:43:15 +00:00
dsl b7ab3bd781 Add example of how to use the ?: modifier properly. 2009-10-01 21:40:31 +00:00
wiz 5746a940f5 Don't print "Archive:" line if quiet flag is set. 2009-09-30 10:04:54 +00:00
dsl eab2f96cf5 Fix borked fix for sort relying on realloc() changing the buffer end.
Sorts of more than 8MB data now probably work again.
2009-09-28 20:30:01 +00:00
plunky 98f75b5b42 protecting sockaddr_in6 with -DINET6 2009-09-27 18:19:18 +00:00
dsl 6458ae9cdf Move all the fopen() calls out of the record read routines into the callers.
Split the merge sort so that fsort() can pass the 'FILE *' of the temporary
files to be merged into the merge code.
Don't rely on realloc() not moving the end address of a buffer!
Rework merge sort so that it sorts pointers to 'struct mfile' and only
copies about sort record descriptors.
No functional change intended.
2009-09-26 21:16:55 +00:00
plunky 48b6f8e46b Add a new feature, allow to specify an alternative PSM value for the
RFCOMM protocol to use in client or server mode. Also, handle the case
where service search of the remote device returns non-standard PSM.
2009-09-24 18:30:37 +00:00
dsl 800732bfdc Fix sort -u, PR/42094 2009-09-19 16:18:00 +00:00
joerg 1d5ec6dab9 Implement rename query. 2009-09-18 13:05:19 +00:00
dsl fe52672374 Minor tweaks to the key generation for numeric fields.
Use 1's compliment for -ve numbers to avoid confitionals.
2009-09-16 20:56:38 +00:00
degroote 2d48ac808c Import pfsync support from OpenBSD 4.2
Pfsync interface exposes change in the pf(4) over a pseudo-interface, and can
be used to synchronise different pf.

This work was part of my 2009 GSoC

No objection on tech-net@
2009-09-14 10:36:48 +00:00
pgoyette ca6d65ecdd Use PRIu64 for printf'ing stuff. Fixes build breakage on part-amd64
introduced in rev 1.64 (and reverts a partial fix provided in rev 1.65)
2009-09-13 21:46:23 +00:00
elad dc553b0f9c Put some unsigned long long casts (as was in the original printing code).
Should fix build breakage noticed by pgoyette@ on current-users@:

    http://mail-index.netbsd.org/current-users/2009/09/13/msg010554.html

(sorry, don't have an amd64 anymore!)
2009-09-13 19:04:29 +00:00
wiz 76e34094ac Fix section for sysctl xref (it is 3, not 2). 2009-09-13 09:17:26 +00:00
elad a363352277 Checkin work in progress to make netstat use sysctl rather than kvm(3).
This commit mostly adds code written by Claudio Jeker for OpenBSD to
support sysctl in the interface printing parts (-i, -I, -w). The port has
been ported to NetBSD with tiny adjustments -- of course all bugs etc.
are mine.

Also add and document a -X flag to force sysctl usage. The documentation
notes this flag may be removed at any time and its presence should not be
relied on.

Some misc. comments/#ifdef changes/code snippet moves as well.

Please note that no functionality should change as the routing and
interface printing code is still not fully supported.

Mailing list reference:

    http://mail-index.netbsd.org/tech-userlevel/2009/09/09/msg002604.html
2009-09-13 02:53:17 +00:00