Bug 89286
Summary: | Binary compatibility broken: Incorrectly built binary which accesses errno, h_errno or _res directly. | ||
---|---|---|---|
Product: | [Retired] Red Hat Linux | Reporter: | Peter Funk <pf> |
Component: | glibc | Assignee: | Jakub Jelinek <jakub> |
Status: | CLOSED NOTABUG | QA Contact: | |
Severity: | high | Docs Contact: | |
Priority: | medium | ||
Version: | 9 | CC: | fweimer, gsar, joshua, ml, patrick.melo |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | i686 | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2003-04-22 08:05:45 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Peter Funk
2003-04-22 07:54:44 UTC
I mean, fixing this bug doesn't mean he suddenly looses binary compatibility. He just needs to #include <errno.h> (for errno, or <netdb.h> for h_errno or <resolv.h> for _res) in all source files before first use of errno (resp. h_errno resp. _res). The standard clearly says errno can be a macro and since at least 1996 this is the case in glibc. When the vendor fixes its software this way and recompiles against whatever glibc he used for his current binaries, it should work just fine on RHL9 and any future systems with --with-tls --with-__thread glibc (e.g. all systems with NPTL). I think Peter's point is still a valid description of an erroneous warning. 1. "The standard clearly says that errno can be a macro and since at least 1996 this is the case in glibc." The 1995 POSIX std and the C language std do NOT say errno MUST be a macro. 2. While it seems to make sense to report this error in conjunction with threading, is there a reason to NOT support errno as an int on an older (non threaded) application. What is the reason for losing compatibility with older non threaded code? Why did this become such a critical change that it requires a warning message. It causes large sections of code that once ran to become unusable. The 1990 spec was loosened, not discarded. You mean want to see bug#90002 which demonstrates that there is a binary compatibility issue with '_res'. I regard this change to be a significant API change (yes, its now closer to the spec, but its still an API change) which should not have happened without major versioning updates and supplying compat-libraries. I propose that instead of emmitting that warning, the program REFUSE TO RUN unless some special environment variable is set. Reason: I have just spammed our local LUG list with some 100 copies of a message because QMail/serialmail MALFUNCTIONED by not removing already delivered email. Recompiling the affected programs after fixing the include errno.h fixed that problem. Again: this API Change obviously CAN BE HARMFUL, so just letting the program run is not that good an idea. Try using diferent values for LD_ASSUME_KERNEL, see this http://people.redhat.com/drepper/assumekernel.html |