Re: magic file entry to understand core dumps

Jared Mauch (jared@wolverine.hq.cic.net)
Wed, 17 Jul 1996 22:49:10 -0400 (EDT)


Works for me:

lunar:~> make test
cc test.c -o test
./test
lunar:~> ./test
Floating exception (core dumped)
lunar:~> file core
core: ELF 32-bit LSB core file i386 (386 and up) Version 1
lunar:~> cat test.c
main()
{
printf("%d\n", 0/0);
}
lunar:~>

Marty Leisner graced my mailbox with this long sought knowledge:
>
> Does anyone have a magic line to correctly decode a linux elf
> core dump?
>
> I looked in gdb but got pretty confused...(but it seems to understand
> the core file).
>
> It would be worthwhile to write a cheezy program to print the command
> name of the core dump if file can't do it...
>
> marty leisner@sdsp.mc.xerox.com
> Member of the League for Programming Freedom (http://www.lpf.org)
> Any sufficiently advanced technology is indistinguishable from magic
> Arthur C. Clarke, The Lost Worlds of 2001
>