Summary: | objdump memory exhausted on several 8k demos | ||
---|---|---|---|
Product: | binutils | Reporter: | Aaron Paden <aaronbpaden> |
Component: | binutils | Assignee: | Not yet assigned to anyone <unassigned> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | nickc |
Priority: | P2 | ||
Version: | 2.27 | ||
Target Milestone: | --- | ||
Host: | Target: | ||
Build: | Last reconfirmed: | 2017-01-04 00:00:00 | |
Attachments: | Proposed patch |
Description
Aaron Paden
2016-12-31 20:07:22 UTC
Created attachment 9738 [details]
Proposed patch
Hi Aaron,
Please could you try out this patch. It only adds an extra error message,
explaining why space could not be found to allocate the symbol table. It
does not make any attempt to allow objdump to continue working after detecting
the error. I felt that doing so would likely add more bugs to objdump,
which would be bad.
I only tested one file from the repository you indicated, so there may be
others that cause objdump to run out of memory in other ways. If you find
any like this, please feel free to update this bug report with their names
and I will investigate further.
Cheers
Nick
Huh, every exe I've tried said it failed because there were roughly 18.4 quintillion symbols. That... definitely doesn't seem right. :P The master branch has been updated by Nick Clifton <nickc@sourceware.org>: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=98f02962fefbacf1b805e93fb7bddeb58ec6ff70 commit 98f02962fefbacf1b805e93fb7bddeb58ec6ff70 Author: Nick Clifton <nickc@redhat.com> Date: Mon Jan 9 09:27:46 2017 +0000 Improve objdump's behaviour when it encounters a corrupt binary with an excessively large symbol table. PR binutils/21013 * coffgen.c (_bfd_coff_get_external_symbols): Generate an error message if there are too many symbols to load. Yeah - whoever created those binaries is doing some funky things with the COFF/PE headers. Anyway I have now checked the patch into the sources. Cheers Nick |