objdump example: $v+ binutils/objdump -a -b vms-alpha ./testfile binutils/.libs/objdump: ./testfile: File format not recognized Segmentation fault $v-
(the easiest testfile is some text file) backtrace: #0 0x00002b9c3e820540 in vms_close_and_cleanup (abfd=0x7c0ff0) at vms.c:434 #1 0x00002b9c3e573d91 in bfd_close (abfd=0x7c0ff0) at opncls.c:657 (gdb) print abfd->xvec->name $5 = 0x2b9c3e8859c9 "vms-alpha" (gdb) print abfd->tdata.any $6 = (void *) 0x0 (gdb) print abfd->format $7 = bfd_unknown the easiest fixup IMO is in vms_close_and_cleanup() add check: if (abfd->tdata.any == NULL) return TRUE; I think we could also patch bfd_close() to check if (bfd_get_format(abfd) == bfd_unknown) return TRUE; -- Summary: [bfd] vms-alpha segvs, in vms_close_and_cleanup() when we try to load invalid file using it. Product: binutils Version: unspecified Status: NEW Severity: minor Priority: P2 Component: binutils AssignedTo: unassigned at sources dot redhat dot com ReportedBy: darkjames at darkjames dot ath dot cx CC: bug-binutils at gnu dot org GCC build triplet: --enable-targets=all GCC host triplet: x86_64-pc-linux-gnu GCC target triplet: x86_64-pc-linux-gnu http://sourceware.org/bugzilla/show_bug.cgi?id=5535 ------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is. _______________________________________________ bug-binutils mailing list bug-binutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-binutils