Commit Graph

13304 Commits

Author SHA1 Message Date
wiz 15dfd8155b Drop trailing whitespace. 2009-05-01 21:34:45 +00:00
ginsbach 8f7e60d3bc Extend %z to support all RFC-2822 timezone formats. 2009-05-01 20:15:05 +00:00
perry be11851995 Add versions of stpcpy(3), stpncpy(3), strnlen(3), all from FreeBSD.
These are defined in the latest POSIX

Also make related updates to documentation, mostly from FreeBSD,
though I cleaned a few other things up along the way.

Bump shlib_version.

We are still missing strcoll_l, strerror_l, strsignal, strxfrm_l to be
POSIX conformant.
2009-05-01 17:27:01 +00:00
perry 591534100f ANSI function prototypes 2009-05-01 00:28:17 +00:00
perry b34e9d9fea de-__P 2009-05-01 00:20:08 +00:00
wiz 65b128a600 Use Xr for strtok_r reference. Remove trailing whitespace. 2009-04-28 07:51:59 +00:00
reed f3f3915d98 Add some mdoc macros and spell out an abbreviation.
(I shared some of my fixes upstream a few days ago.)
2009-04-28 03:11:45 +00:00
dyoung 46db29bcf1 Bring getifaddrs(3) behavior in line with the documentation: the
ifa_data member of every AF_LINK struct ifaddrs points at the
corresponding struct if_data.  In ifconfig(8), do not try to suppress
duplicate AF_LINK ifaddrs by checking for a NULL ifa_data.

Don't copy out two AF_LINK struct ifaddrs for each active link-layer
address. getifaddrs(3) used to copy out one ifaddrs for the kernel's
RTM_IFINFO message, and one more for the kernel's RTM_NEWADDR message.
I suppress the first duplicate with a highly conservative change that
wastes a little bit of ifaddrs storage.  The storage is not leaked.
2009-04-27 20:10:49 +00:00
pooka 28e32e3408 Provide a stateful mode for readdir/read/write. Using them gives
a measurable boost to some fs-utils commands.
2009-04-26 22:23:01 +00:00
christos 3c2585b945 correct cast to size_t. 2009-04-23 22:09:23 +00:00
agc 9c3b1325df Cast the arg to an unsigned value to let this compile 2009-04-23 03:49:39 +00:00
lukem b129d71a05 Fix -Wcast-qual issue 2009-04-23 01:39:47 +00:00
njoly 41f89f9e08 Include string.h for memset prototype. 2009-04-22 21:52:59 +00:00
christos 0f03f83ae4 Avoid information leaks by zeroing memory, from FreeBSD (we had done some
already)
2009-04-22 18:44:06 +00:00
wiz 48f171ac9f Mark up NULL. New sentence, new line. Bump date for previous. 2009-04-22 07:26:52 +00:00
dyoung c378e7997c For non-AF_LINK ifaddrs, ifa_data is NULL. AFAICT, this has always been
so.  Say so in the documentation.
2009-04-21 23:27:09 +00:00
joerg c4cbdd8e8a Convert to mdoc markup. 2009-04-21 14:46:02 +00:00
christos 2cca8c559f Bring back binary compatibility with the previous version of the resolver.
There was no room to allocate 16 bytes for _rnd in the struct in the _LP64
case, so we dynamically allocate now. Also put the _rnd field last, so that
we are bitwise compatible too. Now of course we've run out of space, so
next time will need to perform more evil tricks to fit.
2009-04-20 14:42:12 +00:00
wiz 51004b901f Remove duplicate 'the' found by Jukka Salmi. 2009-04-20 08:37:22 +00:00
christos 0852251407 PR/41250: David H. Gutteridge: librefuse fuse_opt.h header doesn't accommodate
C++ compilation
2009-04-19 22:25:29 +00:00
mrg fc2793ab5b add some code to cope with dev.db's that have 32 bit time_t's in them.
shouldn't be relevant very much as dev.db should be re-created at boot,
but it helped me at least twice so far...
2009-04-19 10:19:26 +00:00
tsutsui 0d20c5ab69 Resurrect accidentally removed libiscsi, which is not provided by ISC. 2009-04-18 16:31:30 +00:00
christos bda2b43696 remove old bind. 2009-04-18 13:02:27 +00:00
christos b203bfe74f PR/41230: -current: sh(1) endlessly looping in interactive
Fix proposed from Matthew Mondor
2009-04-16 19:39:37 +00:00
wiz 8b5179c21c Add CAVEATS section:
Due to limitations in the current pthread implementation, makecontext(3)
and sigaltstack(2) should not be used in programs which link against
libpthread (whether threads are used or not).

Wording from drochner@ and ad@

Bump date for man pages.

Add note in libpthread/README so it's not forgotten to update the man
pages when the problem is fixed.
2009-04-16 18:37:29 +00:00
christos 1408cbc26a we are not guaranteed that the ext pointer is going to be null at this point
so don't attempt to free.
2009-04-16 14:56:51 +00:00
christos 185e0d409f External stuff does not belong here. It is handled by external/lib when
descending to external from the top level. At least this is the theory
as I understand it.
2009-04-14 17:49:45 +00:00
christos 50ce2a6bdf fix lint issues and actual bugs lint found (missing break statements) 2009-04-12 19:43:37 +00:00
christos 62b7074a71 unhook bind libraries 2009-04-12 17:09:46 +00:00
christos 59a755a40f merge libbind and bump. 2009-04-12 17:07:16 +00:00
christos c6497e5b5f libc portion of libbind from external/bsd/libbind 2009-04-12 16:35:44 +00:00
lukem 83f6c8b3a4 fix -Wcast-qual issue 2009-04-12 14:20:19 +00:00
wiz 55a1b57943 Drop trailing whitespace. 2009-04-11 22:17:52 +00:00
christos 497a527565 make this work properly, by moving to the end of the buffer before starting
the search.
remove clauses 3 + 4.
2009-04-11 21:42:16 +00:00
joerg dab0ac3098 Don't use .Xo/.Xc to work around ancient macro argument limit in groff. 2009-04-11 20:53:15 +00:00
joerg 22ce33e2aa Don't use .Xo/.Xc to avoid ancient macro argument limit. 2009-04-11 20:48:26 +00:00
joerg 59ba3c43a4 -width needs an argument, so provide one. 2009-04-11 20:39:15 +00:00
joerg 9a790c1d7e Add missing .Re. 2009-04-11 20:14:35 +00:00
joerg 33c9c1889e Use semantic markup. 2009-04-11 17:26:32 +00:00
joerg 8feb8b89b7 Remove redundant .Pp. 2009-04-11 17:10:57 +00:00
wiz 0f4e9153b3 Use Aq instead of \*[Lt]...\*[Gt]. 2009-04-11 16:59:05 +00:00
wiz 73bfbb6953 Improve markup. 2009-04-11 16:58:21 +00:00
wiz 25b7d5a452 New sentence, new line.
This page could use more markup.
2009-04-11 16:55:04 +00:00
wiz 7d9f3abb75 Avoid duplicate .Pp. 2009-04-11 16:51:39 +00:00
wiz c32974546d Remove trailing whitespace. 2009-04-11 16:51:28 +00:00
wiz 332088ae2e New sentence, new line. 2009-04-11 16:48:53 +00:00
joerg 6a85fc7cdf Use .Bl -ohang instead of physical markup. 2009-04-11 16:44:01 +00:00
joerg 868fe66e65 Add missing quotes. 2009-04-11 16:29:09 +00:00
joerg 71c479831e Fix markup. 2009-04-11 16:13:49 +00:00
joerg 3d2415a28f Fix markup. 2009-04-11 16:03:29 +00:00
joerg aa21536cc0 Remove .IP, it doesn't change output. 2009-04-11 15:55:28 +00:00
joerg d749557c31 Fix markup. 2009-04-11 15:51:44 +00:00
joerg 0cc93fa086 Use semantic markup. 2009-04-11 15:44:42 +00:00
joerg e112b60607 Fix markup. 2009-04-11 15:37:12 +00:00
joerg 326820b20c Fix missing quote. 2009-04-11 15:36:22 +00:00
joerg d3c6cf0458 .\" are comments, not ./" 2009-04-11 15:35:15 +00:00
joerg 746b955e9e Fix markup. 2009-04-11 15:33:27 +00:00
joerg 592c0f8761 Remove reundant quote. 2009-04-11 15:32:03 +00:00
joerg 79c74bd3c8 Fix markup. 2009-04-11 15:30:49 +00:00
joerg c4d2456ed9 Improve markup. 2009-04-11 15:29:50 +00:00
wiz 24e269dafa Split Nm over two lines. 2009-04-10 23:24:35 +00:00
christos 5207347451 Add a special lint stub for __sigaction14 which broke when we switched
to sigaction_sigtramp.
2009-04-10 23:14:58 +00:00
christos d4bf2b400d take the opportunity of the glob_pattern_p and add memrchr. 2009-04-10 23:14:07 +00:00
christos 3cf907e2b2 add memrchr 2009-04-10 23:13:38 +00:00
ad 4caa909fff softdep is gone 2009-04-10 22:26:10 +00:00
joerg 65a94a80fd Fix markup 2009-04-09 00:06:44 +00:00
joerg 58ad7418e8 No .br after .Sh. 2009-04-09 00:04:34 +00:00
christos 46db7d011d Fix off by one error reported by: Caleb Welton cwelton at greenplum dot com 2009-04-08 21:31:31 +00:00
wiz 68bd1a898e Link glob(3) to glob_pattern_p(3). 2009-04-08 19:28:48 +00:00
wiz c2c2c34d00 Add glob_pattern_p to NAME section. 2009-04-08 19:27:39 +00:00
christos 1ef020be5f add glob_pattern_p for glibc because cvs needs it and it is a huge mess
to compile in the gnu glob code.
2009-04-08 16:28:50 +00:00
pooka 9b83cef174 dump readdir offset 2009-04-06 20:47:17 +00:00
pooka afc5bcc1fa * dump op-specific return info before the generic one
* dump readdir response values
2009-04-06 14:45:11 +00:00
pooka 74e11245a1 MNT_SOFTDEP -> MNT_LOG in example. pointed out by mrg. 2009-04-06 12:03:50 +00:00
pooka efd7bfa323 release root vnode at unmount 2009-04-06 03:27:39 +00:00
christos 3b75967235 make fileio.h work with objdir. 2009-04-06 00:48:19 +00:00
christos b10afc8344 regen 2009-04-06 00:48:04 +00:00
christos 3b4cda0de7 PR/41138: Henning Petersen: Redundant declarations in rpc_internal.h
While here remove __P, KNF.
2009-04-04 15:31:08 +00:00
pooka c69ace3c05 ARGSUSED makes lindt a happy camper 2009-04-02 09:30:41 +00:00
cube 7ad46619fb Make keypad return an int instead of nothing, as the SUS and even
curses_input(3) [!] say it should.

OK'd jdc@.  ABI lawyers say this doesn't need major bump.
2009-04-01 20:59:15 +00:00
drochner f1c955a1b2 Fix the comparision function used by the red-black tree global thread list
implementation:
-don't return a difference, this can overflow
-don't try to substract typed pointers which don't belong to the
 same object, this gives undefined results

This fixes instabilities of programs which use more than a handful
of threads, eg spuriously failing pthread_join().
2009-04-01 10:13:24 +00:00
wiz 3a9e7e68ee Readability improvement. Whitespace nits. 2009-04-01 08:58:47 +00:00
christos 097860c04e cast to size_t to avoid sign / unsigned comparison warning. 2009-03-31 21:33:17 +00:00
christos e6ec3d065c implement RL_PROMPT_{START,END}_IGNORE 2009-03-31 17:53:03 +00:00
christos c8754a5b44 Implement literal prompt sequences. Now someone can implement
RL_PROMPT_START_LITERAL/RL_PROMPT_END_LITERAL :-)
2009-03-31 17:38:27 +00:00
ad 7de9da978b Revert the _lwp_ctl which is causing problem. I did test this locally,
I guess not well enough.
2009-03-30 21:32:51 +00:00
ad 5c670ea686 - Make the threadreg code use _lwp_setprivate() instead of MD hooks.
XXX This must not be enabled by default because the LWP private mechanism
  is reserved for TLS. It is provided only as a test/demo.

  XXX Since ucontext_t does not contain the thread private variable, for a
  short time after threads are created their thread specific data is unset.
  If a signal arrives during that time we are screwed.

- No longer need pthread__osrev.

- Rearrange _lwp_ctl() calls slightly.
2009-03-29 09:30:05 +00:00
mrg fcc023545e - add new RLIMIT_AS (aka RLIMIT_VMEM) resource that limits the total
address space available to processes.  this limit exists in most other
modern unix variants, and like most of them, our defaults are unlimited.
remove the old mmap / rlimit.datasize hack.

- adds the VMCMD_STACK flag to all the stack-creation vmcmd callers.
it is currently unused, but was added a few years ago.

- add a pair of new process size values to kinfo_proc2{}. one is the
total size of the process memory map, and the other is the total size
adjusted for unused stack space (since most processes have a lot of
this...)

- patch sh, and csh to notice RLIMIT_AS.  (in some cases, the alias
RLIMIT_VMEM was already present and used if availble.)

- patch ps, top and systat to notice the new k_vm_vsize member of
kinfo_proc2{}.

- update irix, svr4, svr4_32, linux and osf1 emulations to support
this information.  (freebsd could be done, but that it's best left
as part of the full-update of compat/freebsd.)


this addresses PR 7897.  it also gives correct memory usage values,
which have never been entirely correct (since mmap), and have been
very incorrect since jemalloc() was enabled.

tested on i386 and sparc64, build tested on several other platforms.

thanks to many folks for feedback and testing but most espcially
chuq and yamt for critical suggestions that lead to this patch not
having a special ugliness i wasn't happy with anyway :-)
2009-03-29 01:02:48 +00:00
drochner c4bdad9349 fix typo in sigevent defaults 2009-03-26 16:55:37 +00:00
pooka c67ff2932c Don't abort() if the kernel complains we supplied an invalid type
for lookup, as this most likely means that the fs has some bad file
on it.  Rather, just flag an error to the user and be happy.
2009-03-26 14:03:30 +00:00
uebayasi df37ad1752 Correct the order of arguments in EXAMPLE. Bump date. 2009-03-26 05:00:10 +00:00
wiz 01959862b8 Sort SEE ALSO. 2009-03-25 06:46:21 +00:00
dholland ecb714dc77 Update the note about sync returning before buffers are written: it is a
piece of historical behavior, not a current bug. Also, while here, add a
bit about disk write-back caches and point to dkctl/scsictl.
Bump date. (first time since 1993!)
2009-03-25 05:32:52 +00:00
drochner a75975a121 minor fix in description of an error condition 2009-03-24 22:34:54 +00:00
joerg 4b3b61f0a1 Remove/convert physical markup. 2009-03-23 14:11:27 +00:00
joerg cc420b6c04 ANSIfy. Remove conditionals around __RCSID. 2009-03-20 14:05:54 +00:00
joerg cc5989d71d ANSIfy. Remove conditional macros around __RCSID. 2009-03-20 13:56:57 +00:00
joerg c2d267f257 Remove redundant markup as .Bl does vertical spacing already. 2009-03-15 09:31:07 +00:00
joerg fd0a2075ae Fix markup. 2009-03-15 09:26:07 +00:00
joerg 854ee47087 Declare all columns. 2009-03-15 08:05:22 +00:00
joerg af1b54d7d6 Fix markup of cross reference. 2009-03-15 08:04:12 +00:00
joerg 6edb9354b8 ".The" is not a valid macro, fix up. 2009-03-15 08:02:02 +00:00
wiz 5c82067abe Remove USETBL, now that man page does not need tbl any longer. 2009-03-12 13:52:47 +00:00
joerg 9df66b68e0 Explicitly mark : as literal, use Pq. 2009-03-12 12:51:29 +00:00
joerg 441cf5a9bb Replace physical markup with .Bl -column. 2009-03-12 12:50:31 +00:00
joerg 5d4d55d864 Remove redundant physical markup. Don't workaround ancient macro argment
limit with .Xo/.Xc.
2009-03-12 12:47:49 +00:00
joerg 8c2253d6e8 Use .Bl -column instead of tbl(1) for the device mapping list.
OK jmcneill@
2009-03-12 12:33:46 +00:00
wiz 62fcccac72 Fix error in previous, found by joerg. 2009-03-12 10:18:37 +00:00
wiz 9f5b355274 Use comments instead of .ig (requested by joerg).
Sort errors while here.
2009-03-12 10:16:37 +00:00
wiz cf26bd22fc Do not mark up punctuation. 2009-03-11 16:26:35 +00:00
joerg d23280d626 Fix markup 2009-03-11 13:36:55 +00:00
joerg 0e5f0af7e9 Fix preamble 2009-03-11 13:35:21 +00:00
joerg ec28f83cbc Give the full prototype for all ctype functions/macros.
Remove redundant .br.
2009-03-11 12:57:03 +00:00
joerg 86a5a95669 Remove redundant .br. 2009-03-10 23:49:07 +00:00
joerg edc0d6c151 Fix prologue. 2009-03-10 23:37:01 +00:00
joerg fa91a1ac51 Use .An for author list. 2009-03-10 23:36:10 +00:00
joerg a7d7c3857f Remove redundant .IP. Remove use of .Xo/Xc to workaround ancient macro
argument limit.
2009-03-10 23:25:32 +00:00
joerg bfe775a869 Remove redundant .Pp 2009-03-10 23:14:40 +00:00
wiz 097d2fd1a6 -1 is not a defined value, it is just a value.
On the other hand, minuses need backslashes, otherwise they become hyphens.
2009-03-10 22:55:14 +00:00
joerg e85762f4cf Specify width for tag list 2009-03-10 21:00:47 +00:00
joerg ed0b365527 Use .An for the author instead of more physical .Bl. 2009-03-10 20:59:49 +00:00
christos ae87843e53 make el_gets set the count to -1 on error to distinguish between EOF and
error.
2009-03-10 20:46:15 +00:00
joerg bea55cbff7 Fix markup. 2009-03-10 13:23:39 +00:00
joerg 51fed7bd6c Add missing .Os. 2009-03-10 13:21:52 +00:00
joerg 9d4bdfc640 Use MAP_FAILED and NULL. 2009-03-10 13:15:40 +00:00
joerg 997634fe14 Fix preamble to match order set out by mdoc(7). Discussed with wiz. 2009-03-09 19:24:26 +00:00
tnozaki c7281b0c86 fix static linking setlocale(3) problem, reported by Aran Clauson
at current-users, thanks a lot!
2009-03-09 02:22:25 +00:00
christos ea6a01a6c4 consistency in password prompt setting code (and with ssh) 2009-03-08 19:38:03 +00:00
he 5da54c35c9 Based on input from Eduardo Horvath (eeh@), replace 'stmd' and 'lmd',
which apparently don't exist as instructions, with a sequence of
std / ld instructions.

Also remove the attempted include of ldstm.S which we don't have.
2009-03-08 18:57:12 +00:00
apb 6aae635b8d According to Alexander Bluhm in tech-toolchain on 31 Jan 2009, the way
these files use __weak_alias causes build failures under OpenBSD,
because the OpenBSD __weak_alias macro expects the caller to supply a
semicolon, but the NetBSD __weak_alias macro supplies its own semicolon.

Attempt to fix this by avoiding the use of __weak_alias during a tools
build.
2009-03-06 18:15:23 +00:00
msaitoh 16ed711ed3 fix typo (s/stucture/structure/) 2009-03-05 01:21:57 +00:00
explorer c29ff9b310 a better method to truncate at // marks 2009-03-03 16:22:33 +00:00
explorer 31c448a301 Check for NULL return from strdup() 2009-03-03 15:42:43 +00:00
explorer 7c353a46b6 Ignore the magic // commands in iconv_open(). This was discussed on current-users about a month ago, and ignoring the options was the best suggestion. 2009-03-03 14:39:06 +00:00
wiz 5d5e9aca03 Bump date for previous. 2009-03-03 07:37:48 +00:00
bad adb98feec9 Only add the ZZ capability for termcap entries that are larger than 1023
bytes.

This fixes the problem that enabling the titeInhibit Xresource of xterm has
no effect, because xterm exports a TERMCAP string without ti/te sequences
but doesn't remove the ZZ capability because it doesn't know about it and
termcap(3) ignores the stringe because of the ZZ.

Discussed with and OK'ed by blymn@.
2009-03-02 22:46:21 +00:00
christos c9216fc526 no more weak here. 2009-03-01 19:59:55 +00:00
pgoyette e3eb5958e0 Avoid possible integer overflow and subsequent collateral damage.
Received from OpenBSD via US-CERT as VU #590371.

Original OpenBSD commit log:

> revision 1.42
> date: 2009/02/11 13:24:05;  author: otto;  state: Exp; lines: +9 -1
> Avoid level going negative on deep (i mean really deep) dirs. Reported
> by Maksymilian Arciemowicz. ok kettenis@ millert@
2009-02-28 14:34:18 +00:00
wiz 4760c8b288 New sentence, new line. Use more markup. 2009-02-27 16:48:02 +00:00
pooka cd39a9d18a Remove mentions of MAP_COPY, it's not available and trying to use it
will result in compile failure.
2009-02-27 16:23:54 +00:00
msaitoh 150e7551ec fix mis-evaluating whether a char is digit or not. 2009-02-27 04:18:45 +00:00
ad 07a1846337 Remove pointless AUTHORS sections. The names are in the source and CVS
history along with everyone else who has contributed.
2009-02-25 20:50:16 +00:00
christos 2c266c8a4c version alphasort. 2009-02-24 18:41:40 +00:00
wiz 047cc3e3f6 Sort sections. 2009-02-23 08:27:13 +00:00
ad 59fcf21389 PR kern/26878 FFSv2 + softdep = livelock (no free ram)
PR kern/16942 panic with softdep and quotas
PR kern/19565 panic: softdep_write_inodeblock: indirect pointer #1 mismatch
PR kern/26274 softdep panic: allocdirect_merge: ...
PR kern/26374 Long delay before non-root users can write to softdep partitions
PR kern/28621 1.6.x "vp != NULL" panic in ffs_softdep.c:4653 while unmounting a softdep (+quota) filesystem
PR kern/29513 FFS+Softdep panic with unfsck-able file-corruption
PR kern/31544 The ffs softdep code appears to fail to write dirty bits to disk
PR kern/31981 stopping scsi disk can cause panic (softdep)
PR kern/32116 kernel panic in softdep (assertion failure)
PR kern/32532 softdep_trackbufs deadlock
PR kern/37191 softdep: locking against myself
PR kern/40474 Kernel panic after remounting raid root with softdep

Retire softdep, pass 2. As discussed and later formally announced on the
mailing lists.
2009-02-22 20:28:05 +00:00
christos 4534498c64 Get the ESCDELAY from the environment. 2009-02-22 20:05:48 +00:00
christos 58e089a802 Document curses environment variables. 2009-02-22 20:04:21 +00:00
dholland 45e10be5f4 Add __warn_references to getdirentries(), per PR 37730. Okayed by Christos
a while back.
2009-02-22 06:33:38 +00:00
martin c79c3eed1d Make NAN a compile time constant (with help from the compiler). Suggested
by krister. Fixes PR 40695.
Make references to the old construct (which we can't remove for binary
compatibility reasons) emit a linker warning.
2009-02-22 01:34:01 +00:00
christos 07e886c39c remove VEOF test. the tty is in cooked mode when we are not editing and
the tty driver does the check for us.
2009-02-21 23:35:10 +00:00