| Summary: | Race condition in run-time linker | ||
|---|---|---|---|
| Product: | Base System | Reporter: | Nathan Mower <nmower> |
| Component: | i386 | Assignee: | John Polstra <jdp> |
| Status: | Closed FIXED | ||
| Severity: | Affects Only Me | ||
| Priority: | Normal | ||
| Version: | Unspecified | ||
| Hardware: | Any | ||
| OS: | Any | ||
|
Description
Nathan Mower
2001-07-06 01:00:03 UTC
Responsible Changed From-To: freebsd-bugs->jdp jdp seems to make most of the changes to rtld. jdp: this isn't one of the best bug reports in the world, but perhaps it'll alert you to a possible problem. Actually, I think this is a good bug report. It's very concise, but the submitter's analysis of the problem is stated clearly, and I believe it's 100% correct. This kind of stuff is not easy to debug, so he must have done quite a bit of work to diagnose the problem. (Thank you Nathan!) I'll have to think about the best way to fix it. I want to avoid blocking/unblocking signals in rlock_acquire/rlock_release if possible, because of the cost of the system calls. I have a couple other ideas, but they're not fleshed out yet. Stay tuned. State Changed From-To: open->feedback I think the submitter's analysis of this problem is exactly right. However, after looking into it some more I am inclined to close this PR on the grounds that the bug is in apache rather than in FreeBSD. According to the POSIX standard, a signal handler is allowed to call _exit() but not exit(). If apache's signal handler called _exit() as it ought to do, the atexit() processing would be bypassed, the dynamic linker's termination function would not be called, and this problem would not appear. If I could see a reasonable way to fix this in the dynamic linker without killing performance, I'd gladly fix it. But barring that, I think I'm going to have to point to POSIX and say it's not our bug. I'm putting the PR into the feedback state first, to give the submitter an opportunity to disagree. No disagreement here, John. I'll submit a bug report to Apache.org. Thanks for taking a look at it. State Changed From-To: feedback->closed Submitter says he doesn't object to closing this PR, since the actual bug is in apache. He will send a bug report to the apache team. |