Bug 126677 - Incorrectly built Binary which accesses errno or h_errno needs to be fixed
Incorrectly built Binary which accesses errno or h_errno needs to be fixed
Status: CLOSED WORKSFORME
Product: Fedora
Classification: Fedora
Component: glibc (Show other bugs)
1
All Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
Brian Brock
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2004-06-24 12:55 EDT by Jason Cannavale
Modified: 2007-11-30 17:10 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-06-24 13:03:33 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Jason Cannavale 2004-06-24 12:55:23 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040510

Description of problem:
This error messages keeps showing up, again. I know this was fixed for
RH 9 so at least it wasn't going to STDOUT (via bug #97814), but I'm
curious why it is now showing up in Fedora Core 1 and Fedora Core 2.



Version-Release number of selected component (if applicable):
glibc-2.3.2-101.4

How reproducible:
Always

Steps to Reproduce:
1. run any binary compiled on a system lower than RH 9
2.
3.
    

Actual Results:  "Incorrectly built Binary which accesses errno or
h_errno needs to be fixed" appears on STDOUT instead of STDERR

Additional info:
Comment 1 Jakub Jelinek 2004-06-24 13:03:33 EDT
Works just fine for me:
On FC1:
rpm -q glibc; strace -o e.log ./e; grep writev e.log
glibc-2.3.2-101.4
Incorrectly built binary which accesses errno or h_errno directly. Needs to be fixed.
writev(2, [{"Incorrectly built binary which a"..., 86}], 1) = 86
On FC2:
rpm -q glibc; strace -o e.log ./e; grep writev e.log
glibc-2.3.3-27
Incorrectly built binary which accesses errno or h_errno directly. Needs to be fixed.
writev(2, [{"Incorrectly built binary which a"..., 86}], 1) = 86
Comment 2 Jason Cannavale 2004-06-24 15:16:58 EDT
Is there any possible reason that I could be seeing this? I have about
240 machines, and all of them are reporting the error to STDOUT.
Comment 3 Jakub Jelinek 2004-06-24 15:21:04 EDT
No.  There is just one place where /lib/ld-linux.so.2 reports this
and it puts it on fd 2, not fd 1.
rpm -V your glibc, md5sum /lib/ld-linux.so.2, that's all I can suggest
to you.
Comment 4 Andrea Girardi 2005-09-30 08:57:08 EDT
I've the same problem with FC4. 
Comment 5 Andrea Girardi 2005-09-30 09:21:59 EDT
Sorry for my small reply.

I've downlaoded mess822-0.58-0.i386.rpm. When I try to execute I can see:

Incorrectly built binary which accesses errno or h_errno directly. Needs to be
fixed.

With RH9 it works correctly. I supposed that it's better try to recompile the
source, but, when I try, it doesn't works:


#make
....
./load iftocc mess822.a getln.a strerr.a substdio.a \
stralloc.a alloc.a error.a env.a str.a case.a fs.a open.a 
/usr/bin/ld: errno: TLS definition in /lib/libc.so.6 section .tbss mismatches
non-TLS reference in strerr.a(strerr_sys.o)
/lib/libc.so.6: could not read symbols: Bad value
collect2: ld returned 1 exit status
make: *** [iftocc] Error 1

Comment 6 Jakub Jelinek 2005-09-30 09:25:27 EDT
Buggy software simply has to be fixed, there is no other way around it.
errno is allowed to be a macro by POSIX, and it is a macro in glibc for many
years now.  So declaring errno yourself rather than including <errno.h>
can't work and needs to be fixed.

Note You need to log in before you can comment on or make changes to this bug.