Commit Graph

2261 Commits

Author SHA1 Message Date
peter
9935f1df75 Revert the temporary hack in rev 1.79. 2000-08-01 18:50:29 +00:00
ps
4b4777407a If the format string passed to setproctitle begins with a '-'
character, skip the program name when setting the process title.
Ansified with extreme prejudice.

Reviewed by:	peter
2000-08-01 06:37:09 +00:00
peter
dbb716bd06 Add pointers to rfork_thread(3) 2000-07-31 05:43:43 +00:00
peter
16df36990f Add a skeleton rfork_thread(3) man page. 2000-07-29 12:12:39 +00:00
peter
509e3bd402 Take a shot at implementing a functional rfork_thread() for alpha. This
was not fun and I am not entirely certain of the correctness, but it seems
to work.  (in fact, side by side testing of this code vs the x86 version
turned up hidden bugs in the x86 code).
2000-07-29 11:43:21 +00:00
peter
1ca10015af Fix some rather interesting bugs that managed to not turn up in various
testing and real-life applications:
1) If you returned from the thread function, you got a segv instead of
  calling _exit() with your return code.
2) clean up some bogus stack management.  There was also an underflow
  on function return.
3) when making syscalls, the kernel is expecting to have to leave space
  for the function's return address.  We need to duplicate this.  It was
  an accident that the rfork syscall actually worked here. :-/
2000-07-29 11:34:01 +00:00
peter
6a75b120d2 rfork(2) wrapper for simple rfork-style threads. I have lost count of
the number of times I have given this to people and got asked: why isn't
it in libc?  It is impossible to do this without assembler glue to reset
the stack for the new child process.

int rfork_thread(flags, stack_addr, start_fnc, start_arg)
int flags;                 Flags to rfork system call.  See rfork(2).
void *stack_addr;          Top of stack for thread.
int (*start_fnc)(void *);  Address of thread function to call in child.
void *start_arg;           Argument to pass to the thread function in child.

This is deliberately not documented or prototyped in includes until the
corresponding alpha version is written.
2000-07-29 07:14:04 +00:00
peter
9b8b53fbe4 Deal with the exit entry in MIASM changing to sys_exit.
This Is A Hack(TM).
2000-07-29 00:28:44 +00:00
dillon
93d09cda1f MFC 1.11.2.3 from -stable to -current 2000-07-25 18:50:22 +00:00
sheldonh
7d51c945f4 Clean up some nits, with the permission of the author:
* Grammar fixes.
  * Mark up rfork and vnode as cross-references.
  * Clarify the use of the RFFDG flag to rfork(2).
2000-07-24 18:03:53 +00:00
sheldonh
4001ccb3a6 Remove the reference to KERN_UPDATEINTERVAL and syncer(4), since
KERN_UPDATEINTERVAL can't be used to control sched_sync().  In
fact, there's no easy way to control the syncer with sysctls.

Reported by:	bde
2000-07-22 15:36:36 +00:00
jasone
6e408fc8c9 Use _close() instead of close() in addrconfig() to keep it from becoming a
potential cancellation point in libc_r.
2000-07-21 04:22:39 +00:00
ume
54a296ab27 Copy canonname for *ahost, into static buffer.
Obtained from:	KAME Project
2000-07-20 18:49:35 +00:00
alfred
49401184c1 use .Pp instead of faking it with an extra newline
Pointed out by: sheldonh
2000-07-20 11:05:52 +00:00
alfred
aea8dfef9b document get/set sockopt usage with accept_filter(9) 2000-07-20 10:33:08 +00:00
brian
145f71945d Alocate rcmd{,_af}()'s *ahost argument using malloc() (well
strdup()) rather than pointing it at something that's free()d
(via freeaddrinfo(res)) before the function returns.

I appreciate that this is an API change, but it's the only way
(AFAIK) of doing this without breaking existing code that uses
rcmd{,_af}().

Pointed out by: phkmalloc
2000-07-20 09:05:15 +00:00
sheldonh
37dc146239 Update stale references to update(4) with references to the new
syncer(4) manual page.
2000-07-19 07:39:08 +00:00
ume
174b0abb77 To define A RR to root (.) is valid in DNS. So, h_name = "" shouldn't
be treated as NULL.

PR:		bin/19816
Submitted by:	Bill Fenner <fenner@research.att.com>
Reviewed by:	Atsushi Onoe <onoe@sm.sony.co.jp>
2000-07-19 06:22:01 +00:00
archie
97e87e17de Const'ify parameters to ethers(3) routines as appropriate. 2000-07-18 22:44:52 +00:00
jlemon
7171047204 Simplify kqueue API slightly.
Discussed on:	-arch
2000-07-18 19:31:52 +00:00
alex
d0550d9237 Drop the references to index(3) and rindex(3), which are non-standard
and people shouldn't be encouraged to use them.

Asked by:	sheldonh
2000-07-18 08:05:11 +00:00
jasone
3006cee4d8 Change my email address in the copyright notices for the sake of consistency
(jasone@canonware.com --> jasone@freebsd.org).
2000-07-18 01:38:19 +00:00
jasone
210624f121 Reshuffle the SEE ALSO section.
Prompted by:	sheldonh
2000-07-17 22:33:32 +00:00
alex
62909a46ea Add SEE ALSO section, as with the other string functions.
Submitted by:	dcs
2000-07-17 19:00:26 +00:00
ben
f406ebc1b9 Make the NAME section a bit less confusing.
PR:		19262
Submitted by:	NOKUBI Hirotaka <nokubi@ff.iij4u.or.jp>
Reviewed by:	sheldonh
2000-07-15 13:04:33 +00:00
asmodai
2d06929aed Fix typo, teh -> the. 2000-07-14 11:23:04 +00:00
ben
d6f0a22ddf Fix typo; sa_siginfo -> sa_sigaction
PR:		19602
Submitted by:	Tony Finch <dot@dotat.at>
2000-07-11 11:39:57 +00:00
peter
63c050d16c Try and fix the worst of some highly bogus malloc/free resource
management involving rcmd_af(), getaddrinfo(), freeaddrinfo(), etc.
We set *ahost to point to ai->canonname; and later free the ai-> stuff
and still leave the old pointers in *ahost to the freed data.
Perhaps the best way to deal with this is a static buffer or a static
strdup() that is freed on the next iteration or something.  This gives
me headaches just thinking about this.

The new 'AJ' default for malloc() tripped this up.
2000-07-11 09:31:19 +00:00
green
04ee30c6c3 Actually make it so this Makefile can build grot. 2000-07-10 06:10:47 +00:00
dcs
d035f7d8d4 Add a test case for one of the bugs found on the new additions to
regex(3).
2000-07-09 18:14:39 +00:00
dcs
c2a39d8b09 Spencer's regex(3) test code.
Obtained from: BSD/OS
2000-07-09 18:13:35 +00:00
dcs
2f86797f52 altoffset() always returned whenever it recursed, because at the end
of the processing of the recursion, "scan" would be pointing to O_CH
(or O_QUEST), which would then be interpreted as being the end character
for altoffset().

We avoid this by properly increasing scan before leaving the switch.

Without this, something like (a?b?)?cc would result in a g->moffset of
1 instead of 2.

I added a case to the soon-to-be-imported regex(3) test code to catch
this error.
2000-07-09 17:45:30 +00:00
dcs
13a9107aac Since g->moffset points to the _maximum_ offset at which the must
string may be found (from the beginning of the pattern), the point
at which must is found minus that offset may actually point to some
place before the start of the text.

In that case, make start = start.

Alternatively, this could be tested for in the preceding if, but it
did not occur to me. :-)

Caught by: regex(3) test code
2000-07-09 17:36:53 +00:00
dcs
c6e22d497b Add some casts here and there. 2000-07-09 15:12:28 +00:00
phk
2845a5b541 Turn malloc options "AJ" on by default.
These will be turned off again as we approach 5.0-RELEASE.

If you benchmark things, make sure to
	ln -sf j /etc/malloc.conf
to see "true" performance.
2000-07-09 13:10:18 +00:00
itojun
363b5efd7a reject empty scopeid. use strtoul() for checking all-numericness of
portname.  explicitly reject empty numeric portname.
sync with kame.  based on comments from itohy@netbsd.org
2000-07-09 06:10:01 +00:00
dannyboy
368192edcd First appeared in 2.9BSD, not 3.0.
PR:		19263
Submitted by:	NOKUBI Hirotaka <nokubi@ff.iij4u.or.jp>
Obtained from:	Open|NetBSD
2000-07-08 18:17:12 +00:00
dcs
a7a491c823 Since we have modified charjump to be CHAR_MIN-based, we have to
correct the offset when we free it.

Caught by: phkmalloc
2000-07-08 09:45:17 +00:00
jdp
e5f758a576 Change the dllockinit() interface from "experimental" to
"deprecated" and warn that it will disappear eventually.
2000-07-08 04:17:28 +00:00
ache
202433c0d7 fix comment 2000-07-07 08:24:50 +00:00
dcs
50b6717af1 Do not free NULL pointers. 2000-07-07 07:47:39 +00:00
dcs
88593e5a99 Deal with the signed/unsigned chars issue in a more proper manner. We
use a CHAR_MIN-based array, like elsewhere in the code.

Remove a number of unused variables (some due to the above change, one
that was left after a number of optimizing steps through the source).

Brucified by: bde
2000-07-07 07:46:36 +00:00
jmg
3857031058 remove sys/time.h by instruction from bde. 2000-07-06 22:18:44 +00:00
alfred
9cf69c30c9 cleanup the tsearch import.
remove (comment out) functions defined or depricated elsewhere:
  bsearch, lfind, lsearch, insque, remque

change hcreate to take a size_t rather than uint (essentially the same)

since hcreate/hdestroy are now in <search.h>, remove private search.h
in lib/libc/db/hash/

add $FreeBSD tags to hsearch.c
2000-07-06 20:04:34 +00:00
dcs
e71baf2383 I hate signed chars.^W^W^W^W^WCast to unsigned char before using signed
chars as array indices.
2000-07-06 06:37:30 +00:00
dcs
2d066a2d83 Correct comment to work with test code.
Prevent out of bounds array access in some specific cases.
2000-07-06 06:34:15 +00:00
dcs
5d7c5eed08 Use UCHAR_MAX consistently. 2000-07-06 05:19:29 +00:00
itojun
44ab6a4c89 sync with more recent kame tree.
- correct scoped notation separator (s/@/%/)
- include example and more references
2000-07-05 08:27:50 +00:00
itojun
8d38802086 sync with latest kame.
- permit numeric scopeid, be more careful about buffer size

TODO: 2nd arg type should be socklen_t for RFC2553 conformance,
but due to include file dependency it is not a easy thing to do
(netdb.h does not have socklen_t)
2000-07-05 05:09:17 +00:00
itojun
50e0123ddd sync with kame.
- better return code.  from enami@netbsd
- do not use "class" as variable name.  C++ guy had trouble with it.
2000-07-05 05:07:23 +00:00
rwatson
1349e5a450 o Enable building of libposix1e capability state utility functions and
capability-related syscall wrappers.

Obtained from:	TrustedBSD Project
2000-07-05 04:25:09 +00:00
rwatson
111a0a6e96 o Introduce cap_{get,set}_{file,fd}() syscall wrappers, associated with
soon to be committed syscall stubs.  These calls will be used to get
  and set capability state associated with executables.

Obtained from:	TrustedBSD Project
2000-07-05 04:20:59 +00:00
rwatson
377c3393c9 o When calling the syscall, use &cap instead of cap. Apparently this
error was introduced during the merge; fixing it corrects a (correct)
  warning about types.

Obtained from:	TrustedBSD Project
2000-07-05 04:08:35 +00:00
rwatson
693177f07a o Comment out <sys/audit.h> and <sys/mac.h> since they are not yet
committed

Obtained from:	TrustedBSD Project
2000-07-05 03:30:32 +00:00
itojun
09cb034585 add getifaddrs(3) from bsdi. this is a magic function which lets you grab
interface addresses in a portable manner, without headache of SIOCGIFCONF
or sysctl.  it is in bsdi/openbsd/netbsd already.
from kame tree (actually, mandatory for latest kame tree).
2000-07-05 02:13:17 +00:00
ache
4d4c1623e8 Describe agrument range correctly, according to multibyte(3)
Remove unneded comment
2000-07-03 13:03:15 +00:00
sheldonh
de3d6e2b9e Remove trailing whitespace only. 2000-07-03 08:31:02 +00:00
sheldonh
63172fd7cd Fix overlong line and trailing whitespace introduced in rev 1.8. 2000-07-03 08:28:30 +00:00
sheldonh
24537f6134 Add to the SEE ALSO section, a reference to the RFC mentioned in
text introduced in the previous commit.
2000-07-03 08:26:50 +00:00
green
62753e53e0 Re-pair the MLINKS of unvis.3 with strunvisx.3. This undoubtedly was a
world breakage.
2000-07-03 05:21:43 +00:00
kris
412dc02ecf Previous commit broke the case of chained CNAME entries. Instead handle
the bogus case by being stricter about errors.

Submitted by:   itojun
Obtained from:  KAME
2000-07-03 04:43:14 +00:00
kris
991a8601b5 Fix a nasty bug which would leave the struct hostent incompletely filled out
when parsing certain DNS records during a reverse address resolution. Thus
when code tries to examine the returned host name, it dereferences a null
pointer :-(

Problem noticed by:	ps
2000-07-03 02:33:02 +00:00
alex
fce3810f11 Add strunvisx.3 MLINK. 2000-07-02 21:45:16 +00:00
alex
995a78eb83 Document VIS_HTTPSTYLE:
VIS_HTTPSTYLE is a new encoding style for use in vis(), strvis() and
  strvisx() that escapes characters according to RFC 1808 (URI encoding).

Since decoding of these require different detection of start-points of
  escaped characters, VIS_HTTPSTYLE can be given as flag to unvis().
  unvis() will then properly decode URIs.

A new function appeared, strunvisx(): strunvisx() behaves similar as
  strunvis(), with one exception: It has an additional flag parameter,
  which is passed to unvis() to archive the effect I described above.
2000-07-02 21:31:26 +00:00
dcs
c0e63a3b83 Fix memory leak introduced with regcomp.c rev 1.14. 2000-07-02 15:58:54 +00:00
dcs
6ebebd878b Enhance the optimization provided by pre-matching. Fix style bugs with
previous commits.

At the time we search the pattern for the "must" string, we now compute
the longest offset from the beginning of the pattern at which the must
string might be found. If that offset is found to be infinite (through
use of "+" or "*"), we set it to -1 to disable the heuristics applied
later.

After we are done with pre-matching, we use that offset and the point in
the text at which the must string was found to compute the earliest
point at which the pattern might be found.

Special care should be taken here. The variable "start" is passed to the
automata-processing functions fast() and slow() to indicate the point in
the text at which they should start working from. The real beginning of
the text is passed in a struct match variable m, which is used to check
for anchors. That variable, though, is initialized with "start", so we
must not adjust "start" before "m" is properly initialized.

Simple tests showed a speed increase from 100% to 400%, but they were
biased in that regexec() was called for the whole file instead of line
by line, and parenthized subexpressions were not searched for.

This change adds a single integer to the size of the "guts" structure,
and does not change the ABI.

Further improvements possible:

Since the speed increase observed here is so huge, one intuitive
optimization would be to introduce a bias in the function that computes
the "must" string so as to prefer a smaller string with a finite offset
over a larger one with an infinite offset. Tests have shown this to be a
bad idea, though, as the cost of false pre-matches far outweights the
benefits of a must offset, even in biased situations.

A number of other improvements suggest themselves, though:

	* identify the cases where the pattern is identical to the must
	string, and avoid entering fast() and slow() in these cases.

	* compute the maximum offset from the must string to the end of
	the pattern, and use that to set the point at which fast() and
	slow() should give up trying to find a match, and return then
	return to pre-matching.

	* return all the way to pre-matching if a "match" was found and
	later invalidated by back reference processing. Since back
	references are evil and should be avoided anyway, this is of
	little use.
2000-07-02 10:58:07 +00:00
dcs
2a91c2ea19 Remove from the notes a bug that it's said to have been fixed.
PR: 15561
Submitted by: Martin Kammerhofer <mkamm@gmx.net>
Confirmed by: ache
2000-07-02 10:34:25 +00:00
dan
1f43692f55 Style fixes. 2000-07-01 17:49:34 +00:00
dan
4b9cb06856 Add URI encoding to the vis/unvis routines courtesy of VIS_HTTPSTYLE.
Since alex is a -doc committer, he can update his own manpage. :-)

Also add $FreeBSD$ while I'm here.

Submitted by: alex
2000-07-01 15:55:49 +00:00
alfred
5a1e6c960d bring in binary search tree code.
Obtained from: NetBSD
2000-07-01 06:55:11 +00:00
dcs
103df7a647 Initialize variables used by the Boyer-Moore algorithm.
This should fix core dumps when the must pattern is of length
three or less.

Bug found by: knu
2000-06-29 18:53:55 +00:00
ache
32a6eb4143 Fix assigning alt_month in compatibility code 2000-06-29 17:21:45 +00:00
dcs
83f8b91f10 Add Boyler-Moore algorithm to pre-matching test.
The BM algorithm works by scanning the pattern from right to left,
and jumping as many characters as viable based on the text's mismatched
character and the pattern's already matched suffix.

This typically enable us to test only a fraction of the text's characters,
but has a worse performance than the straight-forward method for small
patterns. Because of this, the BM algorithm will only be used if the
pattern size is at least 4 characters.

Notice that this pre-matching is done on the largest substring of the
regular expression that _must_ be present on the text for a succesful
match to be possible at all.

For instance, "(xyzzy|grues)" will yield a null "must" substring, and,
therefore, not benefit from the BM algorithm at all. Because of the
lack of intelligence of the algorithm that finds the "must" string,
things like "charjump|matchjump" will also yield a null string. To
optimize that, "(char|match)jump" should be used.

The setup time (at regcomp()) for the BM algorithm will most likely
outweight any benefits for one-time matches. Given the slow regex(3)
we have, this is unlikely to be even perceptible, though.

The size of a regex_t structure is increased by 2*sizeof(char*) +
256*sizeof(int) + strlen(must)*sizeof(int). This is all inside the
regex_t's "guts", which is allocated dynamically by regcomp(). If
allocation of either of the two tables fail, the other one is freed.
In this case, the straight-forward algorithm is used for pre-matching.

Tests exercising the code path affected have shown a speed increase of
50% for "must" strings of length four or five.

API and ABI remain unchanged by this commit.

The patch submitted on the PR was not used, as it was non-functional.

PR: 14342
2000-06-29 04:48:34 +00:00
jasone
07f1aa63b8 Fix typo in SEE ALSO section. 2000-06-28 03:15:21 +00:00
jmg
11ff214c03 change first release date to 4.1-R as 5.0-R won't be out for at least a
year (from jkh)..

Caught by:	Fx macro warning on 3.4-R
2000-06-26 21:23:57 +00:00
alex
88a12ef1b1 The argument is not mcontext_t but ucontext_t.
PR:		17836
Submitted by:	Tim Moore <moore@bricoworks.com>
2000-06-26 15:00:25 +00:00
chris
c4b5ff722b Repair a cross-reference to sync(1) that should refer to sync(8). 2000-06-23 20:47:50 +00:00
chris
5991a88b5a Properly separate paragraphs by using `.Pp' instead of a blank line. 2000-06-23 20:35:45 +00:00
chris
29f80c1ee5 Remove blank lines. 2000-06-23 20:34:31 +00:00
sheldonh
5977c0d0d9 Mark up errno as a variable (Va), not as a defined value (Dv).
Do not terminate the cross-reference list in the SEE ALSO section with
a period.
2000-06-23 15:02:29 +00:00
sheldonh
91b47d1840 Apply the accepted line breaking rules. 2000-06-23 15:01:18 +00:00
chris
a6d911fe4e Replace .Va, .Ar and .Nm with .Fa or .Va where necessary, examples:
``.Ar errno'' -> ``.Va errno''
  ``.Nm ops'' -> ``.Fa ops''
  ``.Va fd'' -> ``.Fa fd''
2000-06-23 05:05:44 +00:00
chris
f8c9b87af4 Replace an erroneous .Va error' with .Va errno'. 2000-06-23 04:25:10 +00:00
chris
46adbb377e Replace `FreeBSD 4.0'' with `.Fx 4.0'' and remove a useless empty line
at the end of the file.
2000-06-23 03:50:32 +00:00
chris
c9d8747304 Replace .Va references to function arguments to .Fa references. 2000-06-23 03:43:34 +00:00
ume
7743e6b8d9 Don't call _getipnodebyname_multi(). It fixes the problem that
getaddrinfo() accidentally returns IPv4 mapped IPv6 address instead
of native IPv4 address.
Now, getaddinfo() is scoped address ready.  You can put scoped
address within /etc/hosts.

Obtained from:	KAME Project.
2000-06-20 16:33:33 +00:00
ume
cf9d5ec179 Re-commit DNS IPv6 transport support with fixes for IPv4 only
kernel and compatibility issue.

Obtained from:	KAME Project
2000-06-19 18:25:06 +00:00
joe
05da2699c5 Remove the setflags/getflags routines. Their functionality has
been replaced with the library calls fflagstostr and strtofflags.
2000-06-18 20:10:41 +00:00
joe
3e8b2c5123 Make a note of fflagstostr and strtofflags in the 'see also' section. 2000-06-17 14:03:34 +00:00
joe
c747c3c63a Add strtofflags and fflagstostr to libc. 2000-06-17 11:55:57 +00:00
joe
4946ded616 Modify strtofflags so that it returns a malloced string instead of a
pointer to a static buffer.
2000-06-17 11:09:24 +00:00
joe
af432f252a The "def" arg for fflagstostr is too specialized for ls. The caller
can easily translate from "" to whatever it wants to print if no
flags are set.  (ls prints "-" and mtree prints "none".)

Suggested by:	bde
2000-06-17 01:43:56 +00:00
joe
27d76a0d0f Return of the evil file flags! The {s|g}etflags functions were
renamed to {s|g}etflagsbyname, which received objections.   They're
now called strtofflags (string to file flags) and fflagstostr (file
flags to string).

Suggested by:	bde
2000-06-17 01:28:13 +00:00
ume
8b2d24b89a Backout my previous commit.
Cannot resolve any host on IPv4 only kernel.

Reported by:	ache
2000-06-14 20:51:55 +00:00
alex
df391a5a36 You need options USER_LDT in your kernel to use these functions.
PR:		18943
Submitted by:	Ben Smithurst <ben@scientia.demon.co.uk>
Reviewed by:	asmodai
2000-06-14 13:38:21 +00:00
alex
e568a51fd7 Fix typo: turn of -> turn off.
PR:		18805
Submitted by:	Yoshihiro Ota <ota@mail.drexel.edu>
Kind of Reviewed by:	asmodai ("sure")
2000-06-13 12:50:47 +00:00
ume
74d273c06d DNS IPv6 transport support.
It is nessesary for IPv6 only life.

Obtained from:	KAME
2000-06-11 15:43:34 +00:00
chris
542d0d3b9f - Replace `.Va (cap_t)NULL'' with `.Dv NULL''
- Fix a typo: ``constrains'' -> ``constraints''

Reviewed by:	rwatson
2000-06-09 02:01:27 +00:00
chris
85ea7aa673 - Replace
.Pp
   .Fn func
   .Pp
   Description ...
  with a list (Bl ... Li ... El).
- Remove a superfluous ``.Sh ENVIRONMENT'' and replace it with a ``.Pp''
  within the IMPLEMENTATION DETAILS section.

Reviewed by:	rwatson
2000-06-09 01:59:48 +00:00
jmg
198c5499e5 add a BUGS section on how we can only watch VNODE's on a UFS file system
right now...

I talked w/ phk last night and "fixing" this in a generic way is going
to require a lot of complex thought on stacking let alone the NFS problems..

add missing sys/time.h for struct timespec def...
2000-06-07 22:09:16 +00:00
rwatson
791168a446 o Introduce libposix1e capability support routines, which provide a
standardized interface to the capability support in TrustedBSD.
o Not currently enabled in Makefile, as this code depends on syscalls
  and include files that will be committed at a later date.

Obtained from:	TrustedBSD Project
2000-06-04 22:17:11 +00:00
rwatson
d12b21d070 o Fix incorrect descriptions of cap_get_flag() and cap_set_flag() in
capabilities summary manpage, cap(3).

Obtained from:	TrustedBSD Project
2000-06-04 22:14:10 +00:00
rwatson
de14938f8d o Build and install POSIX.1e capabilities man pages
o Add shared library version 2 to libposix1e given API changes, et al
o Commented out cap_*.c as that is not currently being compiled into
  the library (pending syscalls being committed)

Obtained from:	TrustedBSD Project
2000-06-04 21:25:31 +00:00
rwatson
4b16d857fd o Add posix1e(3) references to acl.3 and cap.3
Obtained from:	TrustedBSD Project
2000-06-04 21:23:20 +00:00
rwatson
1cb9ff5220 o Add mention of capabilities documentation + APIs
o Switch reference to www.trustedbsd.org instead of POSIX.1e implementation
  page
o Add cross references to capabilities man pages
o Remove extended attribute not implemented "BUGS" entry

Obtained from:	TrustedBSD Project
2000-06-04 21:18:20 +00:00
rwatson
9f516a06e7 o Introduce man pages for POSIX.1e capability API
- cap.3 describing library interface
  - cap_*.3 describing specific API calls

APIs to follow relatively soon, code to follow later.

Obtained from:	TrustedBSD Project
2000-06-04 21:15:16 +00:00
rwatson
8f2f5fdfd0 o Remove extra cross reference from acl.3 to acl.3
o Remove "BUGS" entries indicating that there's nowhere to store ACLs as
  we now have extended attributes.

Obtained from:	TrustedBSD Project
2000-06-04 21:10:59 +00:00
ache
50dddc0919 Megre XPG4 code into libc 2000-06-03 12:24:08 +00:00
kris
7d32b42d59 #include <string.h> for memcpy() prototype
Obtained from:	OpenBSD
2000-06-03 00:27:54 +00:00
chris
dbd30701d6 Replace a `manual(section)' reference with a proper .Xr statement. 2000-05-31 21:12:08 +00:00
hoek
710538e8a1 Fix an mdoc-o, and english. 2000-05-31 04:34:23 +00:00
jake
961b97d434 Back out the previous change to the queue(3) interface.
It was not discussed and should probably not happen.

Requested by:		msmith and others
2000-05-26 02:09:24 +00:00
jmg
877050064d fix up the kqueue documentation... comment some things that were left
out that really needed to be here...

Reviewed-by: jlemon
2000-05-24 04:29:57 +00:00
jake
d93fbc9916 Change the way that the queue(3) structures are declared; don't assume that
the type argument to *_HEAD and *_ENTRY is a struct.

Suggested by:	phk
Reviewed by:	phk
Approved by:	mdodd
2000-05-23 20:41:01 +00:00
ghelmer
e814d2a0db Describe errx/warnx in comparison to errc/warnc/err/warn.
Use .Fa instead of .Va for function arguments.

Reviewed by:	sheldonh
2000-05-23 19:52:35 +00:00
green
5c6432f1d5 Back out NOTE_EXIT status reporting pending discussion. 2000-05-21 16:27:41 +00:00
hoek
1043ce86f8 Fix a memory leak in getent() that occurred when the requested entry
could not be found.

PR:		bin/17084
2000-05-21 02:55:09 +00:00
chris
41dd7a13ef Remove a superfluous `.Pp' occuring directly after
`.Sh IMPLEMENTATION NOTES'.
2000-05-19 02:55:43 +00:00
chris
27ba376ce1 Add a note under IMPLEMENTATION NOTES about the behavior of sendfile()
in the threaded library.
2000-05-19 02:53:55 +00:00
peter
7955e776a1 List ECONNRESET as a return value. EINVAL was not documented either. 2000-05-19 01:00:57 +00:00
green
b987a44176 Put the wait(2) exit status in "data" for NOTE_EXIT kevents. 2000-05-17 01:16:11 +00:00
phantom
de0ca848a1 mdoc related fixes:
. synchronize NAME and SYNOPSIS sections
. replace .Ev macros with .Dv / .Er / .Em macros  as mdoc(7)
  specification declare
2000-05-12 10:22:50 +00:00
phantom
cbc680edb7 . fix .Dt macro argument
. spell inet6_rthdr_reverse correctly
2000-05-12 10:07:31 +00:00
bde
d157e2e89e Fixed missing include in synopsis.
Use a long line instead splitting a line with backslash-newline in synopsis.
My synopsis checker doesn't understand backslash-newline.
2000-05-11 16:01:17 +00:00
hoek
04b5c78bd2 When "any" acts as a subject, the verb must agree with whatever any is of. 2000-05-11 05:29:10 +00:00
hoek
21ce388b84 Content-free commit: only remove trailing whitespace 2000-05-11 05:06:00 +00:00
hoek
553c79f74c The accept() function is a call, not an argument. Also, add: serial
comma, missing-hyphen, and a word-erase character.
2000-05-11 05:04:30 +00:00
jhb
13d30a3d17 Finish moving all IEEE fp types to be the same on all arch's. 2000-05-10 19:41:40 +00:00
obrien
a275067a35 Add FreeBSD Id tags. 2000-05-10 19:04:57 +00:00
obrien
4c9cbbd684 fp_except => fp_except_t for consistancy with the i386 and the tradition
C methoid of nameing types.
2000-05-10 19:00:45 +00:00
sheldonh
5443174128 Supply only one author name per instance of %A, as per mdoc.samples(7).
PR:		18465
Submitted by:	Kazu TAKAMUNE <takamune@avrl.mei.co.jp>
2000-05-10 09:49:04 +00:00
itojun
e3ecba77a5 correct possible security issue(s) in name resolution, due to use of
pre-4.9.7 BIND resolver code.
ftp://ftp.kame.net/pub/mail-list/snap-users/2348 for details.

Reviewed by:	ume
2000-05-10 00:47:20 +00:00
sheldonh
14e9cd73ea Fix miscellaneous mdoc macro argument limit infringements.
PR:		18465
Reported by:	Kazu TAKAMUNE <takamune@avrl.mei.co.jp>
2000-05-09 14:02:06 +00:00
jlemon
0a0aeff114 Some mdoc cleanups for the manual page.
Submitted by:  phantom
2000-05-06 13:06:03 +00:00
phantom
a60a1ebfb4 Use `Er' variable to define first column width in ERRORS section. 2000-05-06 12:07:59 +00:00
phantom
d5d092deee mdoc related cleanup:
. use construction ".Aq Pa filename" instead of ".Pa <filename>"
. replace Section Heading macro (.Sh) with Subsection (.Ss) macro for
subsections
2000-05-06 12:05:39 +00:00
phantom
16afabce18 Use suggested by mdoc(7) style section name (ERROR -> ERRORS) 2000-05-06 12:02:18 +00:00
phantom
3a61ac3c01 Use `Er' variable to define first column width in ERRORS section. 2000-05-06 12:00:11 +00:00
mpp
c0f912fb2f Minor mdoc cleanup.
PR:		docs/13218
2000-05-05 02:21:45 +00:00
jlemon
c590c299e3 Add a kqueue(2) manual page. 2000-05-04 20:11:38 +00:00
phantom
cb5fd90ad4 Use `Er' variable to define first column width in ERRORS section. It was
initially suggested by mdoc(7) style, but was broken over the years
2000-05-04 13:09:25 +00:00
phantom
a477158490 mdoc(7) cleanup:
. use real function names as `.Nm' macro argument in NAME section. It allows
them to appear in apropos(1) or whatis(1) output.

. replace empty lines with `.Pp' macro.

. replace hardcoded standard names with their `.St' macro equivalents.

. sort cross references in SEE ALSO section
2000-05-04 08:05:45 +00:00
jasone
bb0124f71c Use assembler directives rather than ALTENTRY() so that longjmp() and
siglongjmp() are weak symbols.  This is necessary to allow static linking
with the linuxthreads library port.
2000-05-04 04:36:26 +00:00
jasone
03d029f134 Add missing man pages. Fix various compliance bugs, mostly having to do with
error return values.  Implement pthread_mutexattr_gettype().

PR:		docs/16537, docs/17538
2000-05-02 06:51:40 +00:00
jasone
dcf0db55cc Remove cancellation point propagation. 2000-04-26 23:17:17 +00:00
jkoshy
bcf41d55dd Fix typo. Use `.Fa' to denote a function argument.
PR:		docs/18214
Submitted by:	Ben Smithurst <ben@scientia.demon.co.uk>
2000-04-26 05:09:22 +00:00
wollman
6f323e4920 Spell MAP_NOSYNC correctly.
Submitted by:	allenc@verinet.com
2000-04-23 15:15:15 +00:00
wollman
363de667b5 .Lb-ify 2000-04-23 02:02:33 +00:00
phantom
13fe72d4bf Introduce .Lb macro to libutil manpages
Sort .Nm values in some manpages
Remove explicit note about compiling with -lutil, it's implicitly
declared by .Lb macro now.
2000-04-22 16:17:00 +00:00
phantom
0660c0586a Introduce .Lb macro to libposix1e manpages
Sort some .Nm values
Decapitalize .Nd values
2000-04-22 16:13:36 +00:00
phantom
c8cd1c858c Introduce .Lb macro to libc_r manpages. 2000-04-22 15:50:29 +00:00
wollman
32fbc9e863 Add shm_open(3) and shm_unlink(3). The documentation could use a good
bit of work (and is stylistically probably the worst manual page
I've ever written).
2000-04-22 15:24:29 +00:00
phantom
5401879e3b Introduce ".Lb" macro to libc manpages.
More libraries manpages updates following.
2000-04-21 09:42:15 +00:00
shin
8b8912f3ff Change getaddrinfo() resolve order
from
  all AAAA trial, then all A trial
to
  try AAAA and A for each trial

TODO: more fix for the case where IPv4 mapped IPv6 addr is disabled

Reviewed by: ume
2000-04-20 03:31:40 +00:00
ache
c3fb688657 Add comment after locales
Use .Li for type

Suggested-by: sheldonh
2000-04-12 18:38:30 +00:00
asmodai
e486fe2ee6 Fix typo, reported by George Cox.
Fix hard sentence breaks.

Submitted by:	George Cox <gjvc@sophos.com>
2000-04-12 13:38:26 +00:00
sheldonh
a365f1d25a Do proper byte swapping in 64bit routines.
PR:		17681
Submitted by:	"David E. Cross" <crossd@cs.rpi.edu>
Obtained from:	NetBSD
2000-04-12 08:41:16 +00:00
ache
3a0797d2a4 Better wording according to multibyte(3)
Better man formatting
Add reference to multibyte(3)
2000-04-11 14:41:37 +00:00
phk
296f8c148a Add a missing THREAD_UNLOCK() found missing by Valentin Nechayev
<netch@segfault.kiev.ua>

Remove allocation failure check from 'A' option, the 'X' option does
this as a standalone check now.
2000-04-10 09:24:44 +00:00
archie
e0670dffd3 Document EWOULDBLOCK as a possible errno return value. 2000-04-09 19:10:57 +00:00
ache
15bf78e6dc Back out valid argument domain change - sneak to this function by error.
Reword test condition better. Previous variant was true for negative
characters too.
2000-03-28 11:46:40 +00:00
ache
68cad6a3ea Describe valid argument domain for 8-bit wide locales to prevent common error
calling ctype functions with signed char as an argument.
2000-03-28 11:36:31 +00:00
jlemon
8ab55710ca Decrement the timeout being passed to poll() if poll was interrupted for
some reason.  This will prevent an infinite loop if (say) a sigalarm is
being scheduled at a more frequent interval than the poll timeout.

PR:	2191, 8847, 10553
2000-03-26 19:20:50 +00:00
charnier
abcb2d08a5 Spelling, fprintf -> err, remove unneeded variable declaration 2000-03-26 15:18:12 +00:00
bde
c5722a7ded Fixed missing #include of <sys/types.h> in synopsis.
Fixed spelling error in prototype for inet_option_space().
Fixed syntax error in prototype for inet6_option_alloc().
2000-03-23 16:29:05 +00:00
bde
fce3c66cc6 Fixed missing #include of <sys/types.h> in synopsis. 2000-03-23 16:20:20 +00:00
bde
d9abbd8cc8 Fixed wrong arg type in synopsis. 2000-03-23 15:28:30 +00:00
jasone
d7816647ef Add a man page for aio_waitcomplete(). Update the aio_cancel() man page to
reflect the fact that aio_cancel() works now.

Submitted by:	Christopher Sedore <cmsedore@maxwell.syr.edu>
2000-03-21 10:25:22 +00:00
bsd
c1a1c736a7 Back out that last commit, it may be insecure (pointed out by Warner
Losh).
2000-03-16 23:53:41 +00:00
bsd
bf05d34440 Slight adjustment to __ivaliduser() - don't ignore the last line in
the .rhosts file just because there is no ending linefeed.
2000-03-16 22:58:34 +00:00
jasone
23c4215cb0 Take care to avoid having "strong" and "weak" symbols of the same name in
libc_r.
2000-03-16 02:14:41 +00:00
jlemon
859f9435c8 Fix uninitialized variable.
Submitted by:	tanimura
2000-03-15 15:04:54 +00:00
shin
602b08acfa Merge from NetBSD. Addition of inet_ntop() and inet_pton() description.
Specified by: Robert Muir <rmuir@looksharp.net>

Obtained from: NetBSD
2000-03-12 19:38:22 +00:00
shin
12c8708cdb Cosmetic fix. Re-order MLINKS for if_indextoname.3 and inet.3 as alphabetical
order.
2000-03-12 19:29:52 +00:00
shin
7fac483886 Correct MLINKS contents for rcmd.3, because it is obsolete due to
recent changes to rcmd.3.

  links to iruserok_af.3, ruserok_af.3 are removed.
  link to iruserok_sa.3 is added.
2000-03-12 19:12:03 +00:00
shin
4a9ac000d9 Import from KAME. Advanced API related function descriptions.
Obtained from: KAME project
2000-03-12 18:45:49 +00:00
jlemon
53f4095f26 Add in IPV4 NIS support.
PR:		17290 (but not the same patch)
Approved by:	jkh
2000-03-09 22:52:30 +00:00
paul
62f215a16f Fix various unsigned vs signed errors that caused problems with uids
and gids bigger than 16 bits. Added checks for uids and gids that are
bigger than 32 bits.

Approved by:	jkh (partly, this fix is bigger than I first intended)
2000-03-09 18:11:16 +00:00
shin
62fa4ac2fe More grammer, wording, and mdoc fixes.
Submitted by: bde
Reviewed by: sheldonh
2000-03-09 16:41:27 +00:00
cracauer
4c5ed2febd Temporary cosmetic change to prevent gcc-2.95.2 from doing an
optimization that generates code our current as doesn't understand.

The result is bad code that damages dynamic symbol locations at
runtime. Ouch. See PR bin/16862 and discussion in -current.

This change will be backed out when gcc and gas are back in sync.

PR:		Fixes bin/16862, but not the underlying problem.
Submitted by:	bde
Approved by:	jdk
2000-03-08 12:46:25 +00:00
shin
1b7dce690e Replace structure copy form ifreq obtained by SIOCGIFADDR
to memcpy(), to avoid unaligned access trap on alpha.

Approved by: jkh
2000-03-03 13:05:00 +00:00
shin
73d476cc64 CMSG_XXX macros alignment fixes to follow RFC2292.
Approved by: jkh

Submitted by: Partly from tech@openbsd
Reviewed by: itojun
2000-03-03 11:13:12 +00:00
bde
d83d7a1636 Fixed wrong function return types in synopsis. 2000-03-03 05:28:51 +00:00
shin
3d5c7f466d -Reflect function name change.
-Added more description.
-Many grammer fix.
-Fix hard sentence break.
-Many other man style fix.

Thanks for bde finding out the problem.
Thanks for sheldon for the patient and thorough review.
:-)

Submitted by: bde
Reviewed by: sheldonh
2000-03-02 15:57:06 +00:00
sheldonh
244b8ead7d Remove more single-space hard sentence breaks. 2000-03-02 14:54:02 +00:00
sheldonh
329223e6f2 Remove single-space hard sentence breaks. These degrade the quality
of the typeset output, tend to make diffs harder to read and provide
bad examples for new-comers to mdoc.
2000-03-02 09:14:21 +00:00
nik
a00cc32757 Fix errors in .Xr usage.
PR:             docs/17057
Submitted by:   Submitted by:   Udo Erdelhoff <ue@nathan.ruhr.de>
2000-03-01 10:48:35 +00:00
ps
c3800346ab Add MAP_NOCORE to mmap(2), and MADV_NOCORE and MADV_CORE to madvise(2).
This
This feature allows you to specify if mmap'd data is included in
an application's corefile.

Change the type of eflags in struct vm_map_entry from u_char to
vm_eflags_t (an unsigned int).

Reviewed by:	dillon,jdp,alfred
Approved by:	jkh
2000-02-28 04:10:35 +00:00
ru
90e3f24f25 Restore [no]{s|u}unlnk' and [no]opaque' support.
Broken in src/bin/ls/stat_flags.c,v 1.12.

PR:		16885
Approved by:	jkh
2000-02-22 08:13:07 +00:00
shin
98f78aba9d Change IPv6 scoped addr format again based on recent standard discussion.
Sorry for the flapping, but no change will be done for 4.0 anymore.
Official standard will be published around April or later.
If different format would be adopted at that time, then support for
the new format will be added to the succeeding FreeBSD 4.x.

Approved by: jkh
2000-02-19 16:10:16 +00:00
dillon
7a2987cf94 Fix null-pointer dereference crash when the system is intentionally
run out of KVM through a mmap()/fork() bomb that allocates hundreds
    of thousands of vm_map_entry structures.

    Add panic to make null-pointer dereference crash a little more verbose.

    Add a new sysctl, vm.max_proc_mmap, which specifies the maximum number
    of mmap()'d spaces (discrete vm_map_entry's in the process).  The value
    defaults to around 9000 for a 128MB machine.  The test is scaled for the
    number of processes sharing a vmspace (aka linux threads).  Setting
    the value to 0 disables the feature.

PR: kern/16573
Approved by: jkh
2000-02-16 21:11:33 +00:00
jasone
940003aae4 Add man pages for the sem_*() functions.
Approved by:	jkh
2000-02-16 19:31:53 +00:00
fenner
2471367d59 Fix coredump in gethostbyaddr() when the returned answer is too large to
fit in the static buffer.  This fix causes it to look like there is no
 data available, which is also wrong but is better than dumping core.

PR:		bin/10344
Reviewed by:	billf
Approved by:	jkh
2000-02-16 04:39:00 +00:00
chris
47ff3cea33 Replace .Os BSD' which caused a troff error with .Bx' which also
happens to be the correct macro to use in this situation.
2000-02-14 01:34:15 +00:00
obrien
098aba5560 Document the support in the kernel for hardware debug registers on the
ix86 platform which allows for hardware watchpoints, etc...

Submitted by:	Brian Dean <brdean@unx.sas.com>
2000-02-12 18:33:54 +00:00
shin
4d04714b75 Add more dual stack consideration.
-Should not error return when rresvport_af() failed for one of dest
     addrs resolved by getaddrinfo().
     Should retry until all dest addr fail.

Approved by: jkh
2000-02-10 19:46:47 +00:00
shin
bf70ca5c10 Let getaddrinfo() and related functions supports traditional IPv4 format
(shortend format, etc)

   Current KAME getaddrinfo() supports only d.d.d.d format IPv4
   addr. But traditionally inet_aton() and etc support other formats.
   (shortend format and octal/deciaml/hex format)
   Aboud this,
    -As far as the discussion on freebsd-current, many people
     think traditional format should also be supported by getaddrinfo().
    -X/Open spec requires getaddrinfo() also support those
     traditional IPv4 format.
    -RFC2553 say nothing about it.
    -As the result of confirmation in ietf/ipng list, there is
     no clear concensus yet, and the reply was, "RFC2553 update
     and X/Open spec will be in sync"

   So takeing these conditions into account, I think
   getaddrinfo() should also support traditional IPv4 format.

Specified by: Marc Schneiders <marc@oldserver.demon.nl>
Approved by: jkh
2000-02-10 02:59:50 +00:00
chris
baab6b00f5 Replace the existing documentation for ``KERN_QUANTUM'' with a more
descriptive (and generally more useful) explanation.
2000-02-10 01:05:21 +00:00
shin
05934f9767 IPv6 scoped addr format is changed as recent KAME change.
KAME scoped addr format is changed recently.
     before:   addr@scope
     now:      scope%addr

   Because the end of IPv6 numeric addr is tend to be truncated in
   `netstat -rn ` output, so placing scope part at starting of addr
   will be convenient.

Approved by: jkh

Obtained from: KAME project
2000-02-09 00:38:06 +00:00
obrien
049c6bbad0 There is a problem in that one cannot use ctype.h at the same time as parts
of the C++ stdlib.  Our ctype.h uses symbols of the form _<X> to denote the
various character classes.  Our ctype.h also extends the usual ctype.h
offering by adding the "_T" (special) class.  Problem is parts of the STL
also use the symbol "_T" as its parameterized type.  These two uses are
incompatible.

Thus change the form of the symbols used in ctype to something that fixes
the current problem and is less likely to cause conflicts in the future.

Requested by:	Tomoaki NISHIYAMA <tomoaki@biol.s.u-tokyo.ac.jp>
Ok'ed by:	JKH
2000-02-08 07:43:26 +00:00
joe
b57f9be4b7 Revert part of the last commit, remove {g|s}etflags from the libc
interface, and statically link them to the programs using them.
These functions, upon reflection and discussion, are too generically
named for a library interface with such specific functionality.
Also the api that they use, whilst ok for private use, isn't good
enough for a libc function.

Additionally there were complications with the build/install-world
process.  It depends heavily upon xinstall, which got broken by
the change in api, and caused bootstrap problems and general mayhem.

There is work in progress to address future problems that may be
caused by changes in install-chain tools, and better names for
{g|s}etflags can be derived when some future program requires them.
For now the code has been left in src/lib/libc/gen (it started off
in src/bin/ls).

It's important to provide library functions for manipulating file
flag strings if we ever want this interface to be adopted outside
of the source tree, but now isn't necessarily the right moment
with 4.0-release just around the corner.

Approved:	jkh
2000-02-05 18:42:36 +00:00
shin
9742b65930 sync iruserok() extension API with other BSDs
Some of rcmd related function is need to be updated to
  support IPv6. Some of them are already updated as standard
  document. But there is also several de-facto functions and
  they are not listed in standard documents.
  They are,

    iruserok()  (used by rlogind, rshd)
    ruserok()   (used by kerberos, etc)

  KAME package updated those functions in original way.

    iruserok_af()
    ruserok_af()

  But recently there was discussion on IETF IPng mailing
  list about how to sync those API, and it is decided,

    -Those function is not standard and not documented.
    -But let BSDs sync their API as de-facto.

  And after some discussion, it is announced that

    -add update to iruserok() as iruserok_sa()
    -no ruserok() API change(it is only updated internaly)

So I sync those API before 4.0 is released.
The changes are,
   -prototype changes
   -ruserok() internal update (use iruserok_sa() inside)
   -removal of ruserok_af()
   -change iruserok_af() as static functioin, and also prefix the name with __.
   -add iruserok_sa() (Just call __iruserok_af() inside)
   -adding flag AI_ALL to getipnodebyaddr() called from __icheckhost().
    This is necessary to support IPv4 communication via AF_INET6 socket
    could be correctly authenticated via iruserok_sa()
   -irusreok_af() call is replaced to iruserok_sa() call
    in rlogind, and rshd.

Approved by: jkh
2000-02-01 15:55:56 +00:00
chris
ed1d6704fb Merge from RELENG_3 (oops):
resolved_name	-> resolved_path
    resolvedname	-> resolved_path
2000-01-29 19:43:25 +00:00
jasone
b7a1b427de Undo the ill-conceived breakage of the previous commit and really fix:
For libc_r renamed syscalls, correct symbol naming from
_thread_sys_foo() <-- _foo() to _thread_sys_foo() <-- _foo() <-- foo().  This
is necessary for system calls which libc_r doesn't define foo().

Some weak symbols such as poll() are defined twice.  From what I understand,
depending on one weak symbol or the other to be used is a bad idea.  All
such weak symbols defined in the libc_r-specific code should therefore be
made strong (non-weak?).

Simplify PSEUDO() to not define any weak symbols, since they aren't ever
needed.

alpha/SYS.h:

Correct reversed usage of WEAK_ALIAS(), which has reversed arguments from
__weak_reference().  Also, fix reversal of symbols, so that syscall foo()
is a weak alias for _foo().

Add WEAK_ALIAS() call to PRSYSCALL(), which unlike the i386 version of
PRSYSCALL(), is not defined in terms of PSYSCALL().

Make PSEUDO() equivalent to the i386 version.
2000-01-29 12:50:47 +00:00
mpp
0fbb016487 Fix various typos and mdoc style issues.
Reviewed by:	rwatson
2000-01-29 04:18:51 +00:00
chris
3e0ef0bbfc Grammar fix: `Different than'' should really be `different from''. 2000-01-29 01:54:59 +00:00
jdp
1a300d3c49 Revive the warning that dllockinit() is experimental and subject to
change.
2000-01-29 01:33:21 +00:00
jasone
d6a7c1c554 For syscalls that are renamed to _thread_sys_foo, create a weak alias
called _foo, not _thread_sys_foo.
2000-01-28 22:47:21 +00:00
rwatson
e94ca06e82 Introduce ACL man pages en masse for library calls, and general introduction.
Introduce ACL man pages en masse for library calls, and general introduction.

Also, fix acl_valid.c non-portable calls to include _np in their names,
making them standard-happy as well as consistent with acl.h
2000-01-28 20:07:00 +00:00
joerg
3322d89b34 There were so far only 42 different conversion specifications in
strftime(3), add another one. :)  %z yields the local timezone's offset
in hours and minutes, as used in RFC822 headers.  There's a precedence
for this in Lunux' libc, and Internet software (like Perl scripts)
start using it.

OKed by (wrt. the code freeze): jkh
2000-01-28 17:40:42 +00:00
bde
45880f1288 Install setflags.3 and its link to getflags.3. 2000-01-28 07:14:52 +00:00
jasone
8abe2a2d86 Simplify sytem call renaming. Instead of _foo() <-- _libc_foo <-- foo(),
just use _foo() <-- foo().  In the case of a libpthread that doesn't do
call conversion (such as linuxthreads and our upcoming libpthread), this
is adequate.  In the case of libc_r, we still need three names, which are
now _thread_sys_foo() <-- _foo() <-- foo().

Convert all internal libc usage of: aio_suspend(), close(), fsync(), msync(),
nanosleep(), open(), fcntl(), read(), and write() to _foo() instead of foo().

Remove all internal libc usage of: creat(), pause(), sleep(), system(),
tcdrain(), wait(), and waitpid().

Make thread cancellation fully POSIX-compliant.

Suggested by:	deischen
2000-01-27 23:07:25 +00:00
joe
f1a9497df5 Historically file flags (schg, uschg, etc) have been converted from
string to u_long and back using two functions, flags_to_string and
string_to_flags, which co-existed with 'ls'.  As time has progressed
more and more other tools have used these private functions to
manipulate the file flags.

Recently I moved these functions from /usr/src/bin/ls to libutil,
but after some discussion with bde it's been decided that they
really ought to go in libc.

There are two already existing libc functions for manipulating file
modes:  setmode and getmode.  In keeping with these flags_to_string
has been renamed getflags and string_to_flags to setflags.

The manual page could probably be improved upon ;)
2000-01-27 21:17:01 +00:00
ru
275ce72a91 o Back out rev 1.4 - reallocf() failure clobbers existing `environ'.
o Do not override `environ' if realloc() fails, leave it intact.
o Set `alloced' only when memory is actually allocated.

PR:		bin/5604 (2nd part)
Reviewed by:	bde
2000-01-27 16:12:03 +00:00
shin
3e351708f6 Allow reverse lookup for loopback addr.
This is merge from recent KAME fix to be more compliant with RFC2553.

Obtained from: KAME project
2000-01-27 13:00:14 +00:00
bde
f82c03e087 Fixed wrong includes in synopsis.
Updated date.  1987 was a while ago.

Removed trailing comma in NAME section.

Uncapitalised Bindresvport and Bindresvport_sa in DESCRIPTION section.
Don't use .Nm there either.

Added bindresvport_sa() to the RETURN VALUES and ERROR sections.
2000-01-27 02:55:01 +00:00
archie
af563a21f8 Document the memory leak that is inherent in FreeBSD's semantics
for getenv()/putenv().

PR:	10341 5604
2000-01-26 22:10:56 +00:00
rwatson
4f34910f07 A few more touchups:
- clean up unneeded AFS ID type
- Add Coda, NTFS, NWFS ACL types
- Add acl_dup() prototype
- Remove acl_calc_mask, which belongs in the editing library
- Introduce posix1e.3, a man page introducing POSIX.1e library calls
  (more man pages to follow)
2000-01-26 16:15:48 +00:00
shin
5c7b071c6b Removed 3rd arg from bindresvport_sa() call, because the 3rd arg have been
already removed.

Specified by: Philipp Mergenthaler <un1i@rz.uni-karlsruhe.de>
2000-01-26 14:13:41 +00:00
shin
eb4463295b bindresvport related changes
-changed bindresvport2 to bindresvport_sa
 -merged the man into bindresvport.3

All discussion between Jean-Luc Richier <Jean-Luc.Richier@imag.fr>,
Theo de Raadt <deraadt@cvs.openbsd.org>, itojun, is reflected to
this code. (Actually Theo de Raadt write the code simultaneously as the
discussion change.)
2000-01-26 09:02:42 +00:00
shin
a67280b2ce Fix getaddrinfo() behaviour to be more compliant with RFC2553. Patches are
obtained from itojun.
  -don't filter address families which are not supported by system at
   FQDN resolving.
  -don't do reverse lookup

I think I checked all lib and tools which use getaddrinfo() if
this change affect them.

Obtained from: KAME project
2000-01-26 08:37:29 +00:00
rwatson
bca585a108 Minor fixes to library interface to improve POSIX.1e compliance. This
adds _np to a couple of function prototypes that provided more broad/useful
interfaces than POSIX.1e interfaces included.

Also, move from using a heuristic to identify POSIX.1e-semantic ACLs to
using different ACL types for non-POSIX.1e ACLs.  This should clean up the
existing fuzzy logic that determined when acl_sort() should be applied
before kernel submission.
2000-01-26 04:19:38 +00:00
shin
fc29f7bcf7 several tcp apps IPv6 update
-inetd
 -rshd
 -rlogind
 -telnetd
 -rsh
 -rlogin

Reviewed by: freebsd-arch, cvs-committers
Obtained from: KAME project
2000-01-25 14:52:10 +00:00
sheldonh
4497b0fbab Improve the explanation on the (in)security of mktemp(3). 2000-01-25 13:58:46 +00:00
guido
f0ee13b810 We _do_ support MS_ASYNC
Reviewed by:	Matthew Dillon <dillon@apollo.backplane.com>
2000-01-24 18:35:16 +00:00
alfred
18f642a248 Clarify that we don't offer hard realtime.
Split timeval options into 3 paragraphs, it's easier on my eyes.
2000-01-24 02:13:21 +00:00
jasone
303a1b5e43 Remove unnecessary alternate entry points for *setjmp(). Make the main
entry point the standard name when not compiling libc_r (for example,
longjmp is the main entry point instead of __longjmp).

Suggested by:	bde
2000-01-20 21:58:27 +00:00
jasone
271b33587d Move ENTRY and ALTENTRY definitions to asm.h where they belong.
Unbreak profiling.  Again.

Submitted by:	bde
2000-01-20 03:15:01 +00:00
sheldonh
ad9f304ef9 Although it should be obvious that the 3-digit numeric values of the
characters shown are octal, state this explicitly for the easily
misled.
2000-01-19 16:21:05 +00:00
sheldonh
74366b47ef Make the quotes in the #include line visible. 2000-01-19 13:27:03 +00:00
jasone
2c6582da15 Make minor entry point changes to support libc_r. 2000-01-19 07:01:40 +00:00
rwatson
bfcdbb7508 Fix bde'isms in acl/extattr syscall interface, renaming syscalls to
prettier (?) names, adding some const's around here, et al.

This is commit 4 out of 3, updating the userland library to reflect kernel
interface changes.

Reviewed by:	bde
2000-01-19 06:13:59 +00:00
wpaul
81ac67ad74 Close PR#16028. Make the sanity check saner. The condition that we
check for on the server may arise legitimately on the client. The
correct way to check for a zero record length is to check for it
without the LAST_FRAG marker in it, since it's legal to send a LAST_FRAG
marker with 0 bytes of data.

PR:		misc/16028
2000-01-19 06:12:32 +00:00
chris
5abc54f36b Document KERN_QUANTUM under CTL_KERN
PR:		15637
Submitted by:	jhs
2000-01-19 05:32:27 +00:00
chris
0d97bae686 Document isnanf() for checking if a float is NaN (``Not-a-Number'') and
create a link from isnanf.3 to isinf.3.

PR:		13878
2000-01-19 04:58:39 +00:00
markm
df0e9dcbe4 This man page is not needed; it just gets jumped on later when libcrypt
is installed.
Submitted by:	bde
2000-01-18 18:25:45 +00:00
sheldonh
960ecfb171 Add HISTORY.
Submitted by:	obrien
2000-01-18 12:50:13 +00:00
bde
cc85ed5238 Fixed missing backslash in previous commit. Adding setresuid.2 has taken
4 commits and 2 world breakages so far.
2000-01-18 05:38:05 +00:00
sheldonh
ab8476344d Fix line too long style bug in the previous commit (which, by the
way, unbroke world).
2000-01-18 05:15:26 +00:00
ache
92d07f2587 add setresuid.2 2000-01-18 04:37:21 +00:00
rwatson
a9df9c5f9f acl_delete_default_file() changed to acl_delete_def_file() 2000-01-17 17:48:22 +00:00
sheldonh
e6afbccaac Add manual pages for the newly added setres[ug]id system calls. 2000-01-17 15:01:42 +00:00
kris
f7cc1d01ee We no longer care about the VAX and Tahoe compilers :-) 2000-01-17 01:28:00 +00:00
rwatson
e48c1317b1 Oops, didn't commit the Makefile for libposix1e--this should fix build
problems.

Reviewed by:	eivind
2000-01-15 23:33:49 +00:00
rwatson
71ddc09478 libposix1e provides userland library calls for the POSIX.1e security
interface.  This commit introduces the library, as well as a modest
subset of the ACL calls, with some modifications to support multiple
ACL semantics.

Reviewed by:	eivind
2000-01-15 19:44:27 +00:00
bde
3c0d60caf9 Fixed corrupted tabs in previous commit. 2000-01-14 15:47:00 +00:00
shin
16085f4294 libc rcmd update for IPv6.
A new function bindresvport2(), AF independent version of bindresvport()
is also added.

Reviewed by: sumikawa
Obtained from: KAME project
2000-01-13 15:09:48 +00:00
asmodai
67fa8a58e3 Correct placement of $FreeBSD$ CVS identifier. 2000-01-13 14:27:44 +00:00
asmodai
520393ee7a Change `from'' to `to''.
PR:		15729
Submitted by:	Kim Toms
2000-01-13 14:26:23 +00:00
jasone
226390d852 Fix unresolved _libc_*() references in libc by creating weak aliases
to the respective system call entry points.
2000-01-13 09:26:50 +00:00