summaryrefslogtreecommitdiffstats
path: root/lib/libc
Commit message (Collapse)AuthorAgeFilesLines
* Don't retry connecting via the same medium.ume2000-08-101-16/+8
| | | | | | | | I changed to close to original code before merging IPv6 support. It seems having delay before another try is useless. However, I'm not sure that delay means. So, I leave it as-is. PR: bin/20515
* mention getipnodeby* and get{addr,name}info are not thread-safe. (sync with ↵itojun2000-08-096-21/+110
| | | | | | | kame) s/.Os KAME/.Os/ comment From: Greg Thompson
* If using a DB_RECNO, db::put should return the new key if R_IAFTER isgreen2000-08-081-1/+9
| | | | | | set, not the previous key. Add $FreeBSD$, not taking this off the vendor branch because it's not on.
* Document return value of ENOENT for nonexistent/invalid filter entries.jlemon2000-08-071-0/+2
|
* Fix description of argv[0] passed to interpreted scripts; it's the name ofben2000-08-051-3/+3
| | | | the interpreter, _not_ the argv[0] passed in the original exec() call.
* Prevent internal buffer overflow due to expansion of $LANG and/or namekris2000-08-051-3/+11
| | | | | | argument in catopen(). Reviewed by: chris, -audit
* Calculate the string length of a u_long at compile-time, instead of using akris2000-08-041-5/+17
| | | | hardcoded value.
* Correct factor-of-10 error in INT_STRLEN_MAXIMUM() calculation.kris2000-08-041-1/+3
|
* Correct string length bounds checking.kris2000-08-041-3/+5
|
* Prevent TMPDIR overflow.kris2000-08-041-1/+5
|
* Don't overflow the internal buffer in clnt_sperror()kris2000-08-041-1/+1
|
* sprintf -> snprintf paranoiakris2000-08-041-3/+3
|
* Make sem_post() safe to call from within a signal handler, as required byjasone2000-08-011-0/+3
| | | | POSIX/SUSv2.
* Revert the temporary hack in rev 1.79.peter2000-08-011-1/+1
|
* If the format string passed to setproctitle begins with a '-'ps2000-08-012-24/+14
| | | | | | | character, skip the program name when setting the process title. Ansified with extreme prejudice. Reviewed by: peter
* Add pointers to rfork_thread(3)peter2000-07-311-3/+12
|
* Add a skeleton rfork_thread(3) man page.peter2000-07-292-1/+79
|
* Take a shot at implementing a functional rfork_thread() for alpha. Thispeter2000-07-292-0/+66
| | | | | | 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).
* Fix some rather interesting bugs that managed to not turn up in variouspeter2000-07-291-5/+5
| | | | | | | | | | | 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. :-/
* rfork(2) wrapper for simple rfork-style threads. I have lost count ofpeter2000-07-293-2/+114
| | | | | | | | | | | | | | | 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.
* Deal with the exit entry in MIASM changing to sys_exit.peter2000-07-291-1/+1
| | | | This Is A Hack(TM).
* MFC 1.11.2.3 from -stable to -currentdillon2000-07-251-6/+21
|
* Clean up some nits, with the permission of the author:sheldonh2000-07-241-7/+14
| | | | | | * Grammar fixes. * Mark up rfork and vnode as cross-references. * Clarify the use of the RFFDG flag to rfork(2).
* Remove the reference to KERN_UPDATEINTERVAL and syncer(4), sincesheldonh2000-07-221-6/+0
| | | | | | | 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
* Use _close() instead of close() in addrconfig() to keep it from becoming ajasone2000-07-211-3/+3
| | | | potential cancellation point in libc_r.
* Copy canonname for *ahost, into static buffer.ume2000-07-201-10/+10
| | | | Obtained from: KAME Project
* use .Pp instead of faking it with an extra newlinealfred2000-07-201-1/+1
| | | | Pointed out by: sheldonh
* document get/set sockopt usage with accept_filter(9)alfred2000-07-201-2/+35
|
* Alocate rcmd{,_af}()'s *ahost argument using malloc() (wellbrian2000-07-202-3/+14
| | | | | | | | | | | 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
* Update stale references to update(4) with references to the newsheldonh2000-07-193-4/+4
| | | | syncer(4) manual page.
* To define A RR to root (.) is valid in DNS. So, h_name = "" shouldn'tume2000-07-191-2/+2
| | | | | | | | be treated as NULL. PR: bin/19816 Submitted by: Bill Fenner <fenner@research.att.com> Reviewed by: Atsushi Onoe <onoe@sm.sony.co.jp>
* Const'ify parameters to ethers(3) routines as appropriate.archie2000-07-182-10/+10
|
* Simplify kqueue API slightly.jlemon2000-07-181-2/+2
| | | | Discussed on: -arch
* Drop the references to index(3) and rindex(3), which are non-standardalex2000-07-189-18/+0
| | | | | | and people shouldn't be encouraged to use them. Asked by: sheldonh
* Change my email address in the copyright notices for the sake of consistencyjasone2000-07-187-7/+7
| | | | (jasone@canonware.com --> jasone@freebsd.org).
* Reshuffle the SEE ALSO section.jasone2000-07-173-7/+7
| | | | Prompted by: sheldonh
* Add SEE ALSO section, as with the other string functions.alex2000-07-171-0/+11
| | | | Submitted by: dcs
* Make the NAME section a bit less confusing.ben2000-07-152-2/+2
| | | | | | PR: 19262 Submitted by: NOKUBI Hirotaka <nokubi@ff.iij4u.or.jp> Reviewed by: sheldonh
* Fix typo, teh -> the.asmodai2000-07-141-1/+1
|
* Fix typo; sa_siginfo -> sa_sigactionben2000-07-111-1/+1
| | | | | PR: 19602 Submitted by: Tony Finch <dot@dotat.at>
* Try and fix the worst of some highly bogus malloc/free resourcepeter2000-07-111-1/+1
| | | | | | | | | | | 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.
* Actually make it so this Makefile can build grot.green2000-07-101-1/+8
|
* Add a test case for one of the bugs found on the new additions todcs2000-07-091-0/+1
| | | | regex(3).
* Spencer's regex(3) test code.dcs2000-07-098-0/+1727
| | | | Obtained from: BSD/OS
* altoffset() always returned whenever it recursed, because at the enddcs2000-07-091-0/+4
| | | | | | | | | | | | | | 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.
* Since g->moffset points to the _maximum_ offset at which the mustdcs2000-07-091-1/+1
| | | | | | | | | | | | | 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
* Add some casts here and there.dcs2000-07-091-3/+3
|
* Turn malloc options "AJ" on by default.phk2000-07-091-2/+2
| | | | | | | | 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.
* reject empty scopeid. use strtoul() for checking all-numericness ofitojun2000-07-091-8/+15
| | | | | portname. explicitly reject empty numeric portname. sync with kame. based on comments from itohy@netbsd.org
* First appeared in 2.9BSD, not 3.0.dannyboy2000-07-081-1/+1
| | | | | | PR: 19263 Submitted by: NOKUBI Hirotaka <nokubi@ff.iij4u.or.jp> Obtained from: Open|NetBSD
OpenPOWER on IntegriCloud