lkml.org 
[lkml]   [1996]   [Nov]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectAnother "Exception at ...", elf loader?


Now, that we have this, and everyone seems to calm down, I have a small
problem. It seems that the elf loader currently doesn't handle really
well the case, where an elf binary doesn't have bss or data segments, only
code.

I didn't like the way the GNU utils have a shell script for true/false,
and have rewritten it to be in assembly. Now, it was small, and
statically linked. However, I was not really satisfied, since it had some
superfluous sections (.note, .comment). Ok, I fired up strip, and get rid
of them. And I tried to be very smart, and remove the empty data and bss
sections too. :) All seemed to be well, up until the new exception
handling mechanism. Now, (although it seems to work), it produces an
"Exception at" message. Could someone take a look at it? :) Is it really
a problem, or is it against the standards to have an elf binary which
do only have a .text section?

Janos

[shadow] ~/New 502> ls -al =true
-rwxr-xr-x 1 root root 284 Nov 02 19:38 /bin/true
[shadow] ~/New 503> objdump --disassemble-all /bin/true

/bin/true: file format elf32-i386

No symbols in "/bin/true".
Disassembly of section .text:
08048074 movl $0x1,%eax
08048079 movl $0x0,%ebx
0804807e int $0x80

[shadow] ~/New 504> uuencode true <=true
begin 644 true
M?T5,1@$!`0````````````(``P`!````=(`$"#0```"D`````````#0`(``!
M`"@``P`"``$``````````(`$"`"`!`B`````@`````4`````$```````````
M``````````````````````````````````"X`0```+L`````S8``+G-Y;71A
M8@`N<W1R=&%B`"YS:'-T<G1A8@`N=&5X=```````````````````````````
M````````````````````````````````&P````$````&````=(`$"'0````,
M```````````````$`````````!$````#``````````````"`````(0``````
.`````````0``````````
`
end


\
 
 \ /
  Last update: 2005-03-22 13:38    [W:0.096 / U:3.024 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site