summaryrefslogtreecommitdiffstats
path: root/libexec
Commit message (Collapse)AuthorAgeFilesLines
* Work around an assert failure in the dynamic linker's default threadjdp1999-12-284-16/+32
| | | | | | | | | | | | | | | | locking functions. If an application loads a shared object with dlopen() and the shared object has an init function which requires lazy binding, then _rtld_bind is called when the thread is already inside the dynamic linker. This leads to a recursive acquisition of the lock, which I was not expecting -- hence the assert failure. This work-around makes the default locking functions handle recursive locking. It is NOT the correct fix -- that should be implemented at the generic locking level rather than in the default locking functions. I will implement the correct fix in a future commit. Since the dllockinit() interface will likely need to change, warn about that in both the man page and the header file.
* Add a new function dllockinit() for registering thread lockingjdp1999-12-2711-45/+509
| | | | | | | | | | | | | | | | | | | functions to be used by the dynamic linker. This can be called by threads packages at start-up time. I will add the call to libc_r soon. Also add a default locking method that is used up until dllockinit() is called. The default method works by blocking SIGVTALRM, SIGPROF, and SIGALRM in critical sections. It is based on the observation that most user-space threads packages implement thread preemption with one of these signals (usually SIGVTALRM). The dynamic linker has never been reentrant, but it became less reentrant in revision 1.34 of "src/libexec/rtld-elf/rtld.c". Starting with that revision, multiple threads each doing lazy binding could interfere with each other. The usual symptom was that a symbol was falsely reported as undefined at start-up time. It was rare but not unseen. This commit fixes it.
* Revert the libcrypt/libmd stuff back to how it was. This should not havepeter1999-12-182-4/+4
| | | | | | | | happened as it was working around problems elsewhere (ie: binutils/ld not doing the right thing according to the ELF design). libcrypt has been adjusted to not need the runtime -lmd. It's still not quite right (ld is supposed to work damnit) but at least it doesn't impact all the users of libcrypt in Marcel's cross-build model.
* Add libmd (or move it after libcrypt). We don't want the linker to bemarcel1999-12-162-4/+4
| | | | | smart because it will definitely get it wrong. This popped up during cross-linking.
* Correct the ttys.5 and init.8 manpages with respect to the incorrectsheldonh1999-12-061-1/+11
| | | | | | | | | assumption that only getty processes can be managed. Describe the SysV-like ability to keep arbitrary long-running processes alive using a non-device first field in /etc/ttys. PR: 12767 Submitted by: Peter Jeremy <peter.jeremy@alcatel.com.au>
* Reactivate named-xferpeter1999-11-301-1/+1
|
* Move named and associated tools into a seperate makefile section andpeter1999-11-301-4/+29
| | | | disable them pending an import and cleanup of bind 8.2.2.p5.
* Add a ``-P pidfile'' optionbrian1999-11-232-3/+37
|
* Enable pppoedbrian1999-11-211-1/+1
|
* pppoed(8) - a server to accept PPPoE connectionsbrian1999-11-213-0/+735
|
* In revision 1.21 I changed the search order for shared libraries,jdp1999-11-191-1/+1
| | | | | | | but I forgot to make the corresponding fix to the comment. Rectify that. Submitted by: Tony Finch <fanf@demon.net>
* Fix bootpd for Alpha.marcel1999-11-123-9/+11
| | | | | | | | | | | bptypes.h originally defined int32 to be of type long. This obviously doesn't work on the Alpha. By defining int32 (and u_int32) in terms of int32_t (and u_int32_t) it now is what it says it should be. Two occurrences of 'unsigned int32' have been changed to 'u_int32' for consistency. Submitted by: Wilko Bulte <wilko@yedi.iaf.nl>
* Log username with password failure.eivind1999-11-061-1/+1
| | | | This has proved useful in real life installations.
* Allow for a telnet in secure/ (SRA telnet).markm1999-10-071-1/+1
|
* sync with netbsd PR 8534, fix undefined C code.alfred1999-10-071-1/+1
| | | | Pointed out by: David A. Holland
* .Nm += "rtld"phantom1999-09-283-3/+6
| | | | apropos(1) now knows about rtld(1) manpage.
* Correct spelling : ascii -> ASCIIphantom1999-09-201-1/+1
| | | | | | PR: docs/13702 Submitted by: Stephen J. Roznowski <sjr@home.com> Reviewed by: mpp
* Fix for new Kerberos4. Make a fist cut at PAM-ising while I'm here.markm1999-09-198-326/+388
|
* When a STAT command is sent to ftpd as an out-of-band transmission duringmharo1999-09-121-0/+1
| | | | | | | | a file transfer, the command was mishandled on every other receipt of the command. PR: 13261 Submitted by: Ian Lepore <ian@plutotech.com>
* Fix more Common Error brokenness.markm1999-09-062-4/+4
|
* Add common error lib for the Kerberos case.markm1999-09-061-2/+2
|
* Make jdk-1.1.8 work again. It turns out that some code insidejdp1999-09-051-5/+9
| | | | | | | | | | | | | | | libjava peeks into the dynamic linker's private Obj_Entry structures. My recent changes introduced some new members near the front of the structures, causing libjava to get the wrong fields. This commit moves the new members toward the end of the structure so that the layout of the portion that is relevant to JDK remains the same as before. I will work with the JDK porting team to see if we can come up with a less fragile way for them to do what they need to do. I understand the current approach was necessary in order to work around some limitations of the dynamic linker. Maybe it's not necessary any more.
* Enable -Wformat checking for debug_printf().jdp1999-09-041-1/+3
|
* Change the warning about unrecognized entries in the dynamic tablejdp1999-09-041-2/+2
| | | | | | | to a debug message which is disabled in production builds of the dynamic linker. The condition warned about is normally harmless. PR: bin/12849
* When looking up symbols, search the objects loaded at program startjdp1999-09-041-8/+8
| | | | | | | up first -- before the dlopened DAGs containing the referencing object. This makes dynamically loaded perl modules work properly again.
* Get the actual pathname of the dynamic linker from the executable'sjdp1999-08-303-12/+31
| | | | | | | PT_INTERP program header entry, to ensure that gdb always finds the right dynamic linker. Use obj->relocbase to simplify a few calculations where appropriate.
* When checking to see if a shared object is already loaded, look forjdp1999-08-303-7/+38
| | | | a device/inode match if no pathname match is found.
* Revamp the symbol lookup algorithm to cope better with objectsjdp1999-08-304-82/+245
| | | | | | | | | | | | | | | | | | | | | | loaded separately by dlopen that have global symbols with identical names. Viewing each dlopened object as a DAG which is linked by its DT_NEEDED entries in the dynamic table, the search order is as follows: * If the referencing object was linked with -Bsymbolic, search it internally. * Search all dlopened DAGs containing the referencing object. * Search all objects loaded at program start up. * Search all objects which were dlopened() using the RTLD_GLOBAL flag (which is now supported too). The search terminates as soon as a strong definition is found. Lacking that, the first weak definition is used. These rules match those of Solaris, as best I could determine them from its vague manual pages and the results of experiments I performed. PR: misc/12438
* When honoring -Bsymbolic, still keep searching if only a weakjdp1999-08-301-4/+8
| | | | definition was found in the referencing object.
* Simplify the logic in find_symdef().jdp1999-08-301-45/+41
|
* Add $FreeBSD$ lines to man pages that are missing them to make itmpp1999-08-285-0/+7
| | | | | | | easier for translation teams. PR: docs/13418 Submitted by: Alexey Zelkin <phantom@cris.net>
* $Id$ -> $FreeBSD$peter1999-08-28191-191/+191
|
* unifdef -DINTERNAL_LS - it's too useful to be off by default. If anyonepeter1999-08-265-32/+7
| | | | | really dislikes this, we could add a switch to disable it at runtime and check in popen.c.
* Ufff. cflags -> chflags. I could have sworn this change has been inimp1999-08-211-3/+3
| | | | | | my last three successful make buildworlds... Noticed by: phk
* Remove all flags from devices before we try to assert ownership andimp1999-08-211-1/+3
| | | | | | | set permissions. Bug not fixed: We silently ignore failures of chflags, chmod and chown.
* Add a NULL pointer check whose absence could cause segmentationjdp1999-08-201-6/+6
| | | | | | | violations in certain obscure cases involving failed dlopens. Many thanks to Archie Cobbs for providing me with a good test case. Eliminate a block that existed only to localize a declaration.
* Back out previous commit - it's not necessary now that tty.h properly includesjkh1999-08-091-2/+1
| | | | the queue macros.
* Add a missing include (sys/queue.h for sys/tty.h SLIST usage.)green1999-08-091-1/+2
|
* Correction to previous commit.stark1999-08-081-9/+5
|
* Corrected mistake that was causing daemon to loop without servingstark1999-08-081-2/+2
| | | | | user requests. Note that nothing can be said about the value of 'user' unless User != NULL.
* Change many asserts into normal errors. They were all for conditionsjdp1999-07-183-39/+65
| | | | | | caused by invalid shared objects rather than by internal errors. Enable format string mismatch checking for _rtld_error().
* Change the symbol used to find the end of an object's address spacejdp1999-07-141-2/+2
| | | | | from "end" to "_end". The former does not exist in most shared libraries. This fixes problems in dladdr() and dlsym(RTLD_NEXT, ...).
* Fix a couple of typos.mpp1999-07-121-3/+3
| | | | | PR: 12610 Submitted by: Seth <seth@freebie.dp.ny.frb.org>
* Add code to 'handle' R_ALPHA_NONE relocations by ignoring them.dfr1999-07-121-1/+4
|
* Add a MAINTAINER line naming myself. We control the vertical. Wejdp1999-07-091-1/+2
| | | | control the horizontal.
* Fix bug: if a dlopen() failed (e.g., because of undefined symbols),jdp1999-07-091-38/+44
| | | | | | | | | | the dynamic linker didn't clean up properly. A subsequent dlopen() of the same object would appear to succeed. Another excellent fix from Max Khon. PR: bin/12471 Submitted by: Max Khon <fjoe@iclub.nsu.ru>
* Shake hands with GDB a little bit earlier so that it is possible tojdp1999-07-031-3/+3
| | | | | | debug the init functions. Submitted by: dfr
* Update the SYNOPSIS to reflect that the -l option can be specifiedmpp1999-06-281-2/+3
| | | | | | more than once. Pointed-out-by: sheldonh
* Fix a reference counting problem when using dlopen(NULL, ...).jdp1999-06-251-3/+4
| | | | PR: bin/12129
* Fix a serious performance bug for large programs on the Alpha,jdp1999-06-257-103/+231
| | | | | | | | | | | | | | | discovered by Hidetoshi Shimokawa. Large programs need multiple GOTs. The lazy binding stub in the PLT can be reached from any of these GOTs, but the dynamic linker only has enough information to fix up the first GOT entry. Thus calls through the other GOTs went through the time-consuming lazy binding process on every call. This fix rewrites the PLT entries themselves to bypass the lazy binding. Tested by Hidetoshi Shimokawa and Steve Price. Reviewed by: Doug Rabson <dfr@freebsd.org>
OpenPOWER on IntegriCloud