summaryrefslogtreecommitdiffstats
path: root/lib/libc
Commit message (Collapse)AuthorAgeFilesLines
* - add getproto{byname,bynumber,ent}_r for internal use within libc.ume2005-04-194-53/+181
| | | | - make getproto{byname,bynumber,ent} thread-safe.
* - nuke deprecated and unused getnodeby(3).ume2005-04-191-31/+0
| | | | | | - remove unused variable. Obtained from: KAME
* rename the NIS related fields to have yp_ prefix.ume2005-04-184-38/+38
| | | | Suggested by: delphij
* Do not check whether a pointer is NULL, since free(3) already takes care ofdelphij2005-04-181-6/+3
| | | | | | this case. Reviewed by: ume
* Add a sysctl that returns the full path of a process' text file.das2005-04-181-3/+9
| | | | | This information is needed by things like `gdb -p' and Sun's javac, and previously it could only be obtained via procfs
* Fix build for !YP case.delphij2005-04-171-0/+4
| | | | | BTW. Shall we change these fields to have yp_ prefix? That will make the code easier to read.
* libc-internal interfaces should have two underscores in frontume2005-04-174-12/+12
| | | | | | of their names. Pointed out by: das
* Wrong working directory, sorry. The previous patch was what I havedelphij2005-04-171-5/+0
| | | | | | seen in NetBSD's tree, and this one is what I have submitted for review. Pointy hat to: me
* Remove a check about whether sa->sa_len is equal to salen fromdelphij2005-04-171-0/+2
| | | | | | | | | | | getnameinfo(3). POSIX standard does not require a sa_len field in sockaddr struct, hence such requirement will cause problem for portability. PR: standards/80008 Requested by: Xin Liu <lx@knight.6test.edu.cn> Reviewed by: freebsd-standards (das) MFC After: 2 weeks
* Be bug-for-bug compatible with the C standard with respect todas2005-04-162-4/+16
| | | | printf("%#.0o", 0). Cite an amusing passage from a defect report.
* Now, our getservbyname(3) is thread-safe. So, we don't needume2005-04-151-14/+1
| | | | to protect it with mutex lock.
* - add getserv{byname,byport,ent}_r for internal use within libc.ume2005-04-154-127/+288
| | | | | | - make getserv{byname,byport,ent} thread-safe. Reviewed by: gnn
* hostalias() is not thread-safe. So, introduce _res_hostalias()ume2005-04-153-14/+29
| | | | | | and use it. Obtained from: BIND9
* remove needless res_init() call.ume2005-04-141-9/+0
| | | | Inspired by: NetBSD
* Attempt i386_set_gsbase() before using the user_ldt code. Unimplementedpeter2005-04-141-1/+4
| | | | sysarch() calls return EINVAL, not SIGSYS.. so we can trivially adapt.
* Add stubs for the %fs/%gs base management calls.peter2005-04-145-0/+149
|
* Add a machine-specific, optimized implementation of strcat.alc2005-04-102-1/+166
| | | | | | PR: 73111 Submitted by: Ville-Pertti Keinonen <will@iki.fi> (taken from NetBSD) MFC after: 3 weeks
* Eliminate a conditional branch and as a side-effect eliminate a branch toalc2005-04-101-5/+4
| | | | | | | | a return instruction. (The latter is discouraged by the Opteron optimization manual because it disables branch prediction for the return instruction.) Reviewed by: bde
* Add a machine-specific, optimized implementation of strcpy.alc2005-04-102-1/+113
| | | | | | PR: 73111 Submitted by: Ville-Pertti Keinonen <will@iki.fi> (taken from NetBSD) MFC after: 3 weeks
* Add a machine-specific, optimized implementation of strcmp.alc2005-04-092-1/+75
| | | | | | PR: 73111 Submitted by: Ville-Pertti Keinonen <will@iki.fi> (taken from NetBSD) MFC after: 3 weeks
* unbreak build without YP defined.ume2005-04-091-0/+4
| | | | Submitted by: Andrea Campi <andrea+freebsd_cvs_at_webcom.it>
* Remove unused variables and assignments.stefanf2005-04-084-9/+3
|
* Use prototypes in the function definitions.stefanf2005-04-082-34/+14
|
* Remove unused variable.stefanf2005-04-081-3/+2
|
* Add machine-specific, optimized implementations of bcmp and memcmp.alc2005-04-083-1/+67
| | | | | | PR: 73111 Submitted by: Ville-Pertti Keinonen <will@iki.fi> (taken from NetBSD) MFC after: 3 weeks
* Eliminate unneeded instructions that are a vestige of mechanicalalc2005-04-081-10/+4
| | | | translation from i386.
* Eliminate an unneeded instruction that is a vestige of mechanicalalc2005-04-071-7/+5
| | | | translation from i386.
* Fix strict-alias warnings by removing excessive (and wrong) casts.peter2005-04-072-2/+2
|
* Add machine-specific, optimized implementations of bcopy, bzero, memcpy,alc2005-04-076-0/+212
| | | | | | | | memmove, and memset. PR: 73111 Submitted by: Ville-Pertti Keinonen <will@iki.fi> (taken from NetBSD) MFC after: 3 weeks
* - we are no longer shareing any resources to be locked betweenume2005-04-062-27/+12
| | | | | | getaddrinfo(3) and getipnodeby*(3). - use definitions in reentrant.h. - remove obsolete comment.
* MUTEX_INITIALIZER should be used instead ofume2005-04-061-1/+1
| | | | PTHREAD_MUTEX_INITIALIZER, here.
* separate gai_strerror(3) from getaddrinfo.c.ume2005-04-063-28/+62
| | | | Requested by: phantom
* make yp stuff re-entrant.ume2005-04-051-26/+15
| | | | Obtained from: NetBSD
* protect _yp_domain with mutex lock.ume2005-04-051-3/+24
| | | | Inspired by: NetBSD
* add missing mutex unlock.ume2005-04-051-0/+1
|
* make _files_getaddrinfo() re-entrant.ume2005-04-041-22/+19
| | | | Obtained from: NetBSD
* Replace the current strspn() and strcspn() with significantly fasterdas2005-04-022-67/+79
| | | | | | | | | implementations inspired by the ones in DragonFly. Unlike the DragonFly versions, these have a small data cache footprint, and my tests show that they're never slower than the old code except when the charset or the span is 0 or 1 characters. This implementation is generally faster than DragonFly until either the charset or the span gets in the ballpark of 32 to 64 characters.
* Add some missing errnos from POSIX. Nothing in FreeBSD generatesdas2005-04-021-0/+5
| | | | | | | | | | these at the moment, but applications that test for them will now have a better chance of compiling. I have intentionally omitted errnos that are only good for STREAMS, since apps that use STREAMS won't compile anyway. The exception is EPROTO, which was apparently intended for STREAMS, but worth having anyway because Linux (mis)uses it for other things.
* nuke the logic for AF_UNSPEC and simplify. once, it was introducedume2005-04-021-301/+47
| | | | | to improve getaddrinfo(3). but, it is not needed for a long time since getaddrinfo(3) became providing its own res_*N() functions.
* Use __weak_reference macro to define weak symbols.davidxu2005-03-211-31/+51
|
* Teach fmtcheck() about the ' (thousands separator) flag.das2005-03-211-1/+1
|
* Add byteorder(9) to SEE ALSO.simon2005-03-201-2/+3
| | | | MFC after: 3 days
* Use the correct values for softfloat, in both the little endian and the bigcognet2005-03-202-8/+13
| | | | endian cases.
* Remove fpsetsticky(). This was added for SysV compatibility, but duedas2005-03-159-162/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | to mistakes from day 1, it has always had semantics inconsistent with SVR4 and its successors. In particular, given argument M: - On Solaris and FreeBSD/{alpha,sparc64}, it clobbers the old flags and *sets* the new flag word to M. (NetBSD, too?) - On FreeBSD/{amd64,i386}, it *clears* the flags that are specified in M and leaves the remaining flags unchanged (modulo a small bug on amd64.) - On FreeBSD/ia64, it is not implemented. There is no way to fix fpsetsticky() to DTRT for both old FreeBSD apps and apps ported from other operating systems, so the best approach seems to be to kill the function and fix any apps that break. I couldn't find any ports that use it, and any such ports would already be broken on FreeBSD/ia64 and Linux anyway. By the way, the routine has always been undocumented in FreeBSD, except for an MLINK to a manpage that doesn't describe it. This manpage has stated since 5.3-RELEASE that the functions it describes are deprecated, so that must mean that functions that it is *supposed* to describe but doesn't are even *more* deprecated. ;-) Note that fpresetsticky() has been retained on FreeBSD/i386. As far as I can tell, no other operating systems or ports of FreeBSD implement it, so there's nothing for it to be inconsistent with. PR: 75862 Suggested by: bde
* Use socklen_t where appropriate.stefanf2005-03-111-2/+2
|
* Avoid pointer arithmetics on void *.stefanf2005-03-101-1/+1
| | | | Approved by: alfred
* Remove an superfluous assignment.stefanf2005-03-101-1/+0
| | | | Approved by: alfred
* Use socklen_t where appropriate.stefanf2005-03-102-2/+3
| | | | Approved by: alfred
* Make MSG_NOSIGNAL available to native programs.alfred2005-03-091-5/+9
| | | | | | Bump FreeBSD_version to note this change. Reviewed by: sobomax
* Have ttyname_r() try to ask DEVFS for the device name.phk2005-03-082-35/+16
| | | | | | Document ttyname_r(). Simplify threaded/unthreaded stuff a lot.
OpenPOWER on IntegriCloud